feat: implement episode image fallback for banned youtube icons

This commit is contained in:
2026-05-02 17:00:23 +02:00
committed by Mikkel Elvers
parent efcd34bcb7
commit 9e0f200ca7
2 changed files with 74 additions and 0 deletions

View File

@@ -63,6 +63,10 @@ func (h *Handler) HandleWatchPage(w http.ResponseWriter, r *http.Request) {
}
}
for i := range episodes.Data {
episodes.Data[i].Images.Jpg.ImageURL = episodes.Data[i].GetFallbackImage(id)
}
sort.Slice(episodes.Data, func(i, j int) bool {
return episodes.Data[i].MalID < episodes.Data[j].MalID
})