1
0
Fork 0
mirror of https://github.com/lidarr/Lidarr synced 2024-12-27 10:07:10 +00:00

do a check to see if daily episode has airdate before attempting a search.

This commit is contained in:
Keivan Beigi 2013-07-30 13:30:34 -07:00 committed by kay.one
parent 17842d3fa1
commit c3b25878d4
2 changed files with 6 additions and 1 deletions

View file

@ -54,6 +54,11 @@ public List<DownloadDecision> EpisodeSearch(int episodeId)
if (series.SeriesType == SeriesTypes.Daily)
{
if (string.IsNullOrWhiteSpace(episode.AirDate))
{
throw new InvalidOperationException("Daily episode is missing AirDate. Try to refresh series info.");
}
return SearchDaily(episode.SeriesId, DateTime.ParseExact(episode.AirDate, Episode.AIR_DATE_FORMAT, CultureInfo.InvariantCulture));
}

View file

@ -72,7 +72,7 @@ public override string ReadString()
return dateVal;
}
public void CheckForError()
private void CheckForError()
{
if (MoveToContent() == XmlNodeType.Element)
{