Commit Graph

132 Commits

Author SHA1 Message Date
Roardom
b2e29cfcf0 fix: migrate boolean columns to tinyint(1)
These columns were previously tiny ints without the (1) display width or regular ints, or smallints. They should all be tinyint(1).
2025-02-19 06:25:21 +00:00
HDVinnie
c48d062a75 Merge pull request #4469 from Roardom/normalize-featured 2025-02-18 10:32:14 -05:00
Roardom
df9fa5004c fix: normalize torrent featured flag
When the featured flag goes out of sync with the featured_torrents table (for reasons still unknown), the torrent is permanently labeled as freeleech, while 100% of traffic is always credited.
2025-02-10 17:47:12 +00:00
Roardom
047f10be36 add: bbcode and linkify blade directives
Also add escaping content inside joypixels blade directive where necessary.
2025-02-01 16:15:34 +00:00
Roardom
604b7e1937 add: spell check ci
Just an initial portion for now fixing incorrect text and preventing future incorrect text. Eventually, I'd like to fix everything still listed under "ignoredWords" in cspell.json.
2025-01-24 11:30:34 +00:00
HDVinnie
d474ee3be4 update: php8.4 support
- makes unit3d php8.4 + required
- fixes multiple implicitly to explicit nullable type
- dependency updates
- github action updates
- carbon 2 needs to move to carbon 3 in separate pr
2025-01-20 00:04:35 -05:00
Roardom
ad716d7cc3 update: remove XSS cleaner and remove XSS vulnerabilities
We've been mostly relying on the 3rd party xss cleaner to make sure user submitted content is clean. This PR fixes up any leftover holes in the bbcode parser that allow xss vulnerabilities, and as a result, the 3rd party library isn't needed anymore. It cleans responsibly by first, running `htmlspecialchars()` over the content, followed by sanitizing the untrusted urls and whitelisting their protocol.
2025-01-20 02:52:42 +00:00
HDVinnie
8a5c9ae43c Merge pull request #4360 from HDInnovations/Request-4353
(Add) Display reports on torrent page
2024-12-01 22:25:20 -05:00
HDVinnie
72dd3c5159 add: display reports on torrent page
- closes request #4353
2024-12-01 22:15:43 -05:00
HDVinnie
192b5ed15d chore: remove unused imports that pint is missing 2024-12-01 20:52:32 -05:00
HDVinnie
8eb1e64cc1 Merge pull request #4300 from Roardom/ansi-db
(Refactor) Use ANSI-compatible syntax for raw database queries
2024-11-03 21:15:37 -05:00
Roardom
40c2889613 refactor: move TorrentFilter trait into TorrentSearchFiltersDTO
The trait is only used in the one place (apart from being used in the request search, which it shouldn't have been used for in the first place).
2024-11-02 10:48:09 +00:00
Roardom
0e4bcb570d refactor: use ANSI-compatible syntax for raw database queries 2024-11-02 04:26:49 +00:00
Roardom
a843a41abc fix: meilisearch playlist search
Requires resyncing meilisearch torrents index.
2024-10-23 19:53:23 +00:00
Roardom
3c7d94d1f0 fix: add torrent trump filtering to meilisearch search
Requires reimporting torrents into meilisearch.
2024-10-20 21:57:20 +00:00
HDVinnie
b17e8d927c Merge pull request #4254 from Roardom/fix-collection-search
(Fix) Meilisearch search for collection id
2024-10-20 17:31:44 -04:00
Roardom
17e0640ad2 fix: meilisearch search for collection id
Requires reimporting torrents into meilisearch.
2024-10-20 13:50:40 +00:00
Roardom
60a909bf33 update: allow sorting torrent list by tmdb rating 2024-10-20 10:01:04 +00:00
HDVinnie
cf60ab6edc update: torrent model 2024-10-07 08:56:06 -04:00
Roardom
b313751581 Revert "revert: #4131"
This reverts commit 1bd9fbab12.
2024-09-22 10:00:12 +00:00
HDVinnie
1bd9fbab12 revert: #4131 2024-09-05 08:23:28 -04:00
Roardom
cbcf34f29b update: don't query database in filter api
Better database performance using raw pagination since it doesn't have to run the data through eloquent resources (bad when there's thousands of TorrentFiles) or query the database to count the count of torrents inside the database for the total item count.
2024-09-02 10:03:38 +00:00
Roardom
7b965b0581 fix: cast relevant values to boolean before updating meilisearch
Fixes searching for torrents which have boolean casts already when upserted via the scout observer but are searched via `1` or `0` in the search filters.
2024-08-29 11:19:03 +00:00
HDVinnie
4d863b7c89 Merge branch '8.x.x' into pr/4029 2024-08-26 20:15:35 -04:00
Roardom
5a9ae37921 update: use system user id constant in more places 2024-08-26 09:28:44 +00:00
Roardom
07dc581a74 fix: don't exclude non-approved torrents from meilisearch index 2024-08-18 23:26:13 +00:00
Roardom
30be9a2608 update: use integer primary key for meilisearch 2024-08-18 21:19:23 +00:00
Roardom
f321e1c889 fix: meilisearch index updates not using makeAllSearchableUsing 2024-08-18 16:59:55 +00:00
Roardom
6d01a6aacd fix: remove release_year from meilisearch
This field has been recently removed from the unit3d schema.
2024-08-18 15:32:42 +00:00
HDVinnie
1087dff233 Merge branch '8.x.x' into meilisearch-3 2024-08-18 01:19:43 -04:00
HDVinnie
f92194281c refactor: release years
- remove the release_year column from the torrents table and just search the movie/tv tables instead
2024-08-13 22:18:38 -04:00
Roardom
acf25f9ebf fix: sync torrents to meilisearch command
`makeAllSearchableUsing()` is not called when calling `->searchable()` so we need to do that manually ourselves.
2024-08-12 09:21:06 +00:00
Roardom
cb41027faf fix: scout json array decoding 2024-08-12 07:19:42 +00:00
Roardom
872d28d9c0 fix: larastan relations 2024-08-09 07:33:56 +00:00
Roardom
fa35e4e5c0 add: use meilisearch to search torrents 2024-08-06 02:15:25 +00:00
HDVinnie
7469a11ea1 add: #4006
- closes #4006
2024-07-28 21:18:09 -04:00
HDVinnie
3ad3bb992b PHP Style Change (Laravel Pint CI) 2024-07-19 03:43:14 +00:00
HDVinnie
8ad0097fc9 fix: HasFactory types 2024-07-18 23:42:13 -04:00
HDVinnie
eddad86406 fix: phpstan errors
- this commit tackles more phpstan errors from the baseline.
- the 2024_06_19_210338_update_colum_types.php migration will have more added to it. This PR is draft until more baaseline errors are closed.
2024-06-19 21:19:02 -04:00
HDVinnie
c4cd52e23b fix: multiple bugs
- adds laravel 11 casts support to phpstan https://github.com/larastan/larastan/blob/2.x/UPGRADE.md#upgrading-to-296-from-295
- fixes multiple bugs found by phpstan
- removes dead code in torrent filter trait
- ignores three new files in phpstan.neon temp until debugged for timeouts
2024-06-19 13:43:59 -04:00
HDVinnie
2378a9f977 add: soft deletes to torrents
- this adds laravel's soft deletes functionality to torrents.
2024-06-13 20:58:19 -04:00
Roardom
68645ef825 fix: types for livewire comments 2024-06-09 04:05:01 +00:00
Roardom
cd8d348b8e fix: strict types
1. Need to use the path of a file and not the object.
2. When a torrent is uploaded, the upload form sends a string for the tmdb and the model is saved with a string and it's the database that does the conversion. We need to cast the string to an int if we want to reuse the model without rehydrating.
3. Some of the first_air_date and last_air_date are null and need to be checked to make sure they follow the correct format.
2024-05-27 06:09:35 +00:00
Roardom
12903f64ac fix: strict type issues
Don't pass null into functions that don't accept null.
2024-05-23 17:40:16 +00:00
Roardom
2e57262e97 fix: strict types phpstan errors 2024-05-23 15:38:35 +00:00
Roardom
b86475a732 add: strict types to all files 2024-05-23 13:58:29 +00:00
HDVinnie
51fa8ec46b update: laravel
- Laravel 11 introduces a new default application structure with fewer default files. Namely, new Laravel applications contain fewer service providers, middleware, and configuration files.

However, it is not recommend that Laravel 10 applications upgrading to Laravel 11 attempt to migrate their application structure, as Laravel 11 has been carefully tuned to also support the Laravel 10 application structure.
2024-04-23 16:06:37 -04:00
Roardom
a37f414145 update: normalize post tips and torrent tips 2024-02-26 09:33:32 +00:00
Roardom
18675b57f1 update: sync peer counts asynchronously
Makes announce processing job code easier to deal with. There is negligible performance loss (<5%) by querying the peer count realtime on the torrents and torrent pages.
2024-02-23 10:30:29 +00:00
HDVinnie
8a03bec818 add: model docblocks
- this resolves some larastan property issues but in return has revealed quite a few issues with our castings and such. baseline has been regenerated so we can work through them. The properties in docblocks are in order and match everything in DB schema wise.
2024-02-07 16:39:43 -05:00