add "Include all released items" toggle, fix orphaned cleanup to use fixed 7-day grace period, fix
placeholder quick sync deleting tv items, other minor changes
re #336, re #268, re #253, re #307
Adds support for IMDb's Top 250 English-language movies list as a new
collection source. The list is available at /chart/top-english-movies/.
- Added TOP_250_ENGLISH_MOVIES enum value and URL mapping
- Added 'top_250_english' subtype to collection sources
- Added UI options in CollectionTypeSection and MultiSourceConfigSection
- Added title presets for the new collection type
- Auto-sets mediaType to 'movie' when selecting this subtype
Closesagregarr/agregarr#330
Co-authored-by: bitr8 <bitr8@users.noreply.github.com>
Validates SVG dimensions before scale calculation to prevent division
by zero. Warns when non-SVG files passed with hint about required format.
Co-authored-by: bitr8 <bitr8@users.noreply.github.com>
Hub items that no longer exist in Plex should not cause errors during
cleanup operations. This matches the behavior of other delete methods
that also ignore 404 responses.
Co-authored-by: bitr8 <bitr8@users.noreply.github.com>
Bug 1: startNow doesn't trigger immediate sync
- When startNow=true, firstSyncAt was set to current time
- calculateNextRunFromFirstSync() returned firstSyncAt + interval (12h later)
- No immediate sync was triggered
- Fix: If firstSyncAt is within 60s of now, queue immediate sync
Bug 2: Deadlock when scheduled sync overlaps full sync
- Scheduled sync acquired API lock in queueCollectionSync()
- Queued sync to process "after main sync completes"
- But main sync was waiting for the same API lock
- Fix: Move API lock acquisition from queue time to execution time
in processLibraryQueue(), after fullSyncRunning check
Co-authored-by: bitr8 <bitr8@users.noreply.github.com>
* fix(api): Sanitize error responses to prevent information disclosure
Add error response sanitization to prevent internal implementation details
from leaking to clients in production:
- New errorResponse.ts utility with whitelist-based message filtering
- Safe message patterns allow user-friendly errors through
- Sensitive patterns block stack traces, file paths, credentials, IPs
- Development mode bypasses sanitization for debugging
- Updated global error handler to use sanitization
This prevents information disclosure while maintaining helpful error
messages for common user-facing issues like "not found" or "invalid".
* style: Fix prettier formatting
* ci: trigger rebuild
* fix(types): Add missing type parameters for Record and Set
- Add <string, string> to Record type declarations for mimeTypeMap
- Add <string> to Set constructor for assetPaths
Fixes TypeScript errors in CI.
* style: format with prettier
---------
Co-authored-by: bitr8 <bitr8@users.noreply.github.com>
When placeholders are cleaned up because real content arrived, Plex
wasn't notified and ghost entries remained in the library. This adds:
- New emptyTrash() method to PlexAPI
- Fire-and-forget scan + empty trash after placeholder cleanup
- New autoEmptyTrash setting (default: true) with UI toggle
- Setting in Plex settings page with "advanced" badge
The scan runs in the background so it doesn't block the sync process.
Co-authored-by: bitr8 <bitr8@users.noreply.github.com>
* fix: skip directories when cleaning orphaned placeholder files
Jellyfin creates .trickplay directories with the same base name as video
files. The cleanup scan matched these directories because they contain
{edition-Trailer} in the path, then failed with EISDIR when attempting
fs.unlink() on them.
Added a stat check to skip non-file entries during orphaned file cleanup.
* fix: remove trickplay directories when deleting placeholders
When Jellyfin scans placeholder videos, it creates .trickplay directories
for video thumbnail scrubbing. These become orphaned when the placeholder
is deleted.
Now removePlaceholder() cleans up the associated .trickplay directory
using fs.rm() with recursive option.
---------
Co-authored-by: bitr8 <bitr8@users.noreply.github.com>
parseConfigIdFromLabel() regex didn't handle source names containing
hyphens or underscores (multi-source, filtered_hub). This caused
DYNAMIC_CYCLE_TITLE collections to create new Plex collections on each
cycle instead of updating the existing one.
Updated regex to allow hyphens/underscores in source names while
ensuring configId capture starts at the first digit.
Co-authored-by: bitr8 <bitr8@users.noreply.github.com>