mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-07-12 08:16:05 -07:00
Fixed the bug where we were displaying shows where we do not have enough information to request #1513
This commit is contained in:
parent
0e8ebcad61
commit
8b4c61c065
2 changed files with 18 additions and 1 deletions
|
@ -65,7 +65,17 @@ namespace Ombi.Core.Engine
|
|||
public async Task<SearchTvShowViewModel> GetShowInformation(int tvdbid)
|
||||
{
|
||||
var show = await TvMazeApi.ShowLookupByTheTvDbId(tvdbid);
|
||||
if (show == null)
|
||||
{
|
||||
// We don't have enough information
|
||||
return null;
|
||||
}
|
||||
var episodes = await TvMazeApi.EpisodeLookup(show.id);
|
||||
if (episodes == null || !episodes.Any())
|
||||
{
|
||||
// We don't have enough information
|
||||
return null;
|
||||
}
|
||||
|
||||
var mapped = Mapper.Map<SearchTvShowViewModel>(show);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue