mirror of
https://github.com/kikootwo/ReadMeABook.git
synced 2026-06-04 13:20:11 +00:00
Add RDT-Client support and Prowlarr prompt
Introduce RDT-Client integration and related UI/behavior changes. - Add RDTClientService extending QBittorrentService with RDT-specific behavior (stale-torrent deletion, postProcess cleanup, no-op categories). - Register 'rdtclient' in supported client types, display names, and protocol mapping; create RDT client factory in DownloadClientManager. - Add RDT-Client card to DownloadClientManagement UI and placeholder URL in DownloadClientModal. - Update qbittorrent service: omit per-torrent savepath/sequential options (favor category/automatic management), make several methods protected, and clean up related comments. - Make organize-files.processor treat rdtclient as a special-case for cleanup (remove local torrent entries after organize). - Add prowlarr service singleton invalidation and call it when Prowlarr settings are updated so background jobs pick up new credentials. - Add confirmation flow when changing Prowlarr URL/API key: new useIndexersSettings logic to detect credential changes, prompt ConfirmModal from IndexersTab, and optionally clear configured indexers on confirmed change. These changes ensure Real-Debrid-backed qBittorrent-compatible clients are supported correctly and that switching Prowlarr credentials is handled safely.
This commit is contained in:
@@ -640,6 +640,18 @@ export class ProwlarrService {
|
||||
// Singleton instance
|
||||
let prowlarrService: ProwlarrService | null = null;
|
||||
|
||||
/**
|
||||
* Invalidate the cached ProwlarrService singleton.
|
||||
* Must be called after updating Prowlarr URL or API key so that
|
||||
* background jobs (search, RSS monitor, etc.) pick up the new credentials.
|
||||
*/
|
||||
export function invalidateProwlarrService(): void {
|
||||
if (prowlarrService) {
|
||||
logger.info('Prowlarr service singleton invalidated — will reconnect with new credentials on next use');
|
||||
}
|
||||
prowlarrService = null;
|
||||
}
|
||||
|
||||
export async function getProwlarrService(): Promise<ProwlarrService> {
|
||||
if (!prowlarrService) {
|
||||
// Get configuration from database
|
||||
|
||||
Reference in New Issue
Block a user