Fixed: Fallback to Title and Year for PTP if IMDB doesn't exist

Fixes #3509
pull/4021/head
Qstick 5 years ago
parent 151bf5b49f
commit 2e5c7e0073

@ -28,7 +28,16 @@ namespace NzbDrone.Core.Indexers.PassThePopcorn
public IndexerPageableRequestChain GetSearchRequests(MovieSearchCriteria searchCriteria)
{
var pageableRequests = new IndexerPageableRequestChain();
pageableRequests.Add(GetRequest(searchCriteria.Movie.ImdbId));
if (searchCriteria.Movie.ImdbId.IsNotNullOrWhiteSpace())
{
pageableRequests.Add(GetRequest(searchCriteria.Movie.ImdbId));
}
else if (searchCriteria.Movie.Year > 0)
{
pageableRequests.Add(GetRequest(string.Format("{0}&year={1}", searchCriteria.Movie.Title, searchCriteria.Movie.Year)));
}
return pageableRequests;
}

Loading…
Cancel
Save