mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-09-27 20:44:00 +02:00
Using Newznab extended attributes to get the tvrage id for matching
This commit is contained in:
@@ -11,7 +11,7 @@ namespace NzbDrone.Core.Parser
|
||||
LocalEpisode GetEpisodes(string filename, Series series);
|
||||
LocalEpisode GetEpisodes(string filename, Series series, bool sceneSource);
|
||||
Series GetSeries(string title);
|
||||
RemoteEpisode Map(ParsedEpisodeInfo parsedEpisodeInfo);
|
||||
RemoteEpisode Map(ParsedEpisodeInfo parsedEpisodeInfo, int tvRageId);
|
||||
}
|
||||
|
||||
public class ParsingService : IParsingService
|
||||
@@ -72,7 +72,7 @@ namespace NzbDrone.Core.Parser
|
||||
return _seriesService.FindByTitle(searchTitle);
|
||||
}
|
||||
|
||||
public RemoteEpisode Map(ParsedEpisodeInfo parsedEpisodeInfo)
|
||||
public RemoteEpisode Map(ParsedEpisodeInfo parsedEpisodeInfo, int tvRageId)
|
||||
{
|
||||
var remoteEpisode = new RemoteEpisode
|
||||
{
|
||||
@@ -81,6 +81,12 @@ namespace NzbDrone.Core.Parser
|
||||
|
||||
var series = _seriesService.FindByTitle(parsedEpisodeInfo.SeriesTitle);
|
||||
|
||||
if (series == null && tvRageId > 0)
|
||||
{
|
||||
series = _seriesService.FindByTvRageId(tvRageId);
|
||||
//TODO: If series is found by TvRageId, we should report it as a scene naming exception, since it will fail to import
|
||||
}
|
||||
|
||||
if (series == null)
|
||||
{
|
||||
_logger.Trace("No matching series {0}", parsedEpisodeInfo.SeriesTitle);
|
||||
|
Reference in New Issue
Block a user