diff --git a/package-lock.json b/package-lock.json index c68c41a..06742db 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "twitch-vod-manager", - "version": "5.0.9", + "version": "5.0.10", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "twitch-vod-manager", - "version": "5.0.9", + "version": "5.0.10", "license": "MIT", "dependencies": { "axios": "^1.16.1", diff --git a/package.json b/package.json index c340e05..b15eb3b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "twitch-vod-manager", - "version": "5.0.9", + "version": "5.0.10", "description": "Twitch VOD Manager - Download Twitch VODs easily", "main": "dist/main.js", "author": "xRangerDE", diff --git a/src/main.ts b/src/main.ts index 019d2c8..c050cd1 100644 --- a/src/main.ts +++ b/src/main.ts @@ -26,6 +26,8 @@ import { normalizePerformanceMode, isPlainObject, VALID_STREAMLINK_QUALITIES, + DEFAULT_METADATA_CACHE_MINUTES, + DEFAULT_PERFORMANCE_MODE, type PerformanceMode, } from './main/domain/config-normalize'; import { CustomClip, MergeGroupItem, MergeGroup, QueueItem, DownloadProgress, DownloadResult } from './types'; @@ -62,8 +64,9 @@ const DEFAULT_DOWNLOAD_PATH = path.join(app.getPath('desktop'), 'Twitch_VODs'); const DEFAULT_FILENAME_TEMPLATE_VOD = '{title}.mp4'; const DEFAULT_FILENAME_TEMPLATE_PARTS = '{date}_Part{part_padded}.mp4'; const DEFAULT_FILENAME_TEMPLATE_CLIP = '{date}_{part}.mp4'; -const DEFAULT_METADATA_CACHE_MINUTES = 10; -const DEFAULT_PERFORMANCE_MODE: PerformanceMode = 'balanced'; +// DEFAULT_METADATA_CACHE_MINUTES + DEFAULT_PERFORMANCE_MODE kommen aus +// ./main/domain/config-normalize (Single-Source-Of-Truth, vermeidet +// Drift wenn man eine der Defaults aendert). const QUEUE_SAVE_DEBOUNCE_MS = 250; const MIN_FREE_DISK_BYTES = 128 * 1024 * 1024; const DEBUG_LOG_FLUSH_INTERVAL_MS = 1000; diff --git a/src/main/domain/config-normalize.ts b/src/main/domain/config-normalize.ts index df5f9e1..e660759 100644 --- a/src/main/domain/config-normalize.ts +++ b/src/main/domain/config-normalize.ts @@ -6,8 +6,8 @@ export const VALID_STREAMLINK_QUALITIES = ['best', 'source', '1080p60', '720p60' const AUTO_RECORD_POLL_MIN_SECONDS = 30; const AUTO_RECORD_POLL_MAX_SECONDS = 1800; -const DEFAULT_METADATA_CACHE_MINUTES = 10; -const DEFAULT_PERFORMANCE_MODE: PerformanceMode = 'balanced'; +export const DEFAULT_METADATA_CACHE_MINUTES = 10; +export const DEFAULT_PERFORMANCE_MODE: PerformanceMode = 'balanced'; /** trim + strip leading @ + lowercase. Verbatim aus altem main.ts. */ export function normalizeLogin(input: string): string {