Skip to content

Commit

Permalink
Fix:Podcast episode cron not adding/removing library items correctly #…
Browse files Browse the repository at this point in the history
  • Loading branch information
advplyr committed Nov 3, 2023
1 parent 20880a6 commit 5220361
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions server/managers/CronManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -127,15 +127,17 @@ class CronManager {
}
}

async executePodcastCron(expression, libraryItemIds) {
Logger.debug(`[CronManager] Start executing podcast cron ${expression} for ${libraryItemIds.length} item(s)`)
async executePodcastCron(expression) {
const podcastCron = this.podcastCrons.find(cron => cron.expression === expression)
if (!podcastCron) {
Logger.error(`[CronManager] Podcast cron not found for expression ${expression}`)
return
}
this.podcastCronExpressionsExecuting.push(expression)

const libraryItemIds = podcastCron.libraryItemIds
Logger.debug(`[CronManager] Start executing podcast cron ${expression} for ${libraryItemIds.length} item(s)`)

// Get podcast library items to check
const libraryItems = []
for (const libraryItemId of libraryItemIds) {
Expand Down

0 comments on commit 5220361

Please sign in to comment.