1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2024-12-16 11:37:58 +02:00

Parsing tvrage id from newznab with TryParse now

This commit is contained in:
Mark McDowall 2013-08-24 21:28:07 -07:00
parent 60dadf96a3
commit c179e715a6
2 changed files with 6 additions and 5 deletions

View File

@ -33,7 +33,12 @@ protected override ReportInfo PostProcessor(XElement item, ReportInfo currentRes
if (rageIdElement != null)
{
currentResult.TvRageId = Convert.ToInt32(rageIdElement.Attribute("value").Value);
int tvRageId;
if (Int32.TryParse(rageIdElement.Attribute("value").Value, out tvRageId))
{
currentResult.TvRageId = tvRageId;
}
}
}

View File

@ -93,14 +93,10 @@ private void RefreshSeriesInfo(Series series)
_logger.WarnException("Couldn't update series path for " + series.Path, e);
}
_seriesService.UpdateSeries(series);
_refreshEpisodeService.RefreshEpisodeInfo(series, tuple.Item2);
_messageAggregator.PublishEvent(new SeriesUpdatedEvent(series));
}
}
}