Skip to content

Commit

Permalink
fix(season-helper): Fixed enhanced episodes not being used
Browse files Browse the repository at this point in the history
  • Loading branch information
TriPSs committed Oct 23, 2020
1 parent 3aa7263 commit 1297188
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions libs/scraper/helpers/season/src/season-helper.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ export class SeasonHelperService {
const tmdbSeason = await this.tmdbService.getSeasonInfo(show, season)

// Also enhance all the episodes
season.episodes.map((episode) => {
season.episodes = season.episodes.map((episode) => {
const tmdbEpisode = tmdbSeason.episodes.find((tmdbEpisode) => (
tmdbEpisode.episodeNumber === episode.number
))
Expand All @@ -190,9 +190,7 @@ export class SeasonHelperService {
images: {
...episode.images,

poster: tmdbEpisode.stillPath
? this.tmdbService.formatImage(tmdbEpisode.stillPath)
: defaultEpisodeImages.poster
poster: this.tmdbService.formatImage(tmdbEpisode.stillPath)
}
}
}
Expand All @@ -213,9 +211,7 @@ export class SeasonHelperService {
images: {
...season.images,

poster: tmdbSeason.posterPath
? this.tmdbService.formatImage(tmdbSeason.posterPath)
: defaultSeasonImages.poster
poster: this.tmdbService.formatImage(tmdbSeason.posterPath)
}
}
} catch (err) {
Expand Down

0 comments on commit 1297188

Please sign in to comment.