Skip to content

Commit

Permalink
Fix: always prune shows before fetching episodes (#16)
Browse files Browse the repository at this point in the history
  • Loading branch information
cbackas authored Aug 4, 2023
1 parent e4af50d commit 6ae8fda
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ export class App {

// run initial scheduled activities
setTVDBLoadingActivity(user)
if (process.env.UPDATE_SHOWS !== 'false') await checkForAiringEpisodes()
await pruneUnsubscribedShows()
if (process.env.UPDATE_SHOWS !== 'false') await checkForAiringEpisodes()
void scheduleAiringMessages(this)
void setRandomShowActivity(user)

Expand All @@ -70,8 +70,8 @@ export class App {

schedule.scheduleJob('lifecycle:4hours:fetchEpisoded', '0 */4 * * *', async () => {
setTVDBLoadingActivity(user)
await checkForAiringEpisodes()
await pruneUnsubscribedShows()
await checkForAiringEpisodes()
await scheduleAiringMessages(this)
void setRandomShowActivity(user)
})
Expand Down

0 comments on commit 6ae8fda

Please sign in to comment.