Add per-episode fallback for incomplete TV seasons

When a complete-season pack cannot be found for a missing/partial season,

fillMissing now searches each missing SxxExx individually and queues the

best episode torrent per gap. Also exposes episode-level detail in the

/fill response and season plan.

Signed-off-by: William Mantly <wmantly@gmail.com>
This commit is contained in:
2026-07-20 14:35:08 -04:00
parent ce0e0bdd4f
commit 803a6db033
3 changed files with 77 additions and 23 deletions
+2 -2
View File
@@ -78,9 +78,9 @@ router.post('/fill', async function(req, res, next){
added_by: req.user.username,
category: pick.category,
});
queued.push({ season: pick.season, name: pick.name });
queued.push({ type: pick.type, season: pick.season, episode: pick.episode, name: pick.name });
}catch(error){
plan.skipped.push({ season: pick.season, reason: error.message });
plan.skipped.push({ season: pick.season, episode: pick.episode, reason: error.message });
}
}
res.json({ title: plan.title, year: plan.year, queued, skipped: plan.skipped });