1
0
mirror of https://github.com/Radarr/Radarr.git synced 2026-04-17 21:26:22 -04:00

Fixed: Don't fail lookup on some IMDB Searches

Fixes #4533
This commit is contained in:
Qstick
2020-06-21 22:11:45 -04:00
parent 3a7c4b2cfe
commit c896833607

View File

@@ -317,6 +317,8 @@ namespace NzbDrone.Core.MetadataSource.SkyHook
lowerTitle = lowerTitle.Replace(".", "");
var parserTitle = lowerTitle;
var parserResult = Parser.Parser.ParseMovieTitle(title, true);
var yearTerm = "";
@@ -324,7 +326,7 @@ namespace NzbDrone.Core.MetadataSource.SkyHook
if (parserResult != null && parserResult.MovieTitle != title)
{
//Parser found something interesting!
lowerTitle = parserResult.MovieTitle.ToLower().Replace(".", " "); //TODO Update so not every period gets replaced (e.g. R.I.P.D.)
parserTitle = parserResult.MovieTitle.ToLower().Replace(".", " "); //TODO Update so not every period gets replaced (e.g. R.I.P.D.)
if (parserResult.Year > 1800)
{
yearTerm = parserResult.Year.ToString();
@@ -343,7 +345,7 @@ namespace NzbDrone.Core.MetadataSource.SkyHook
}
}
lowerTitle = StripTrailingTheFromTitle(lowerTitle);
parserTitle = StripTrailingTheFromTitle(parserTitle);
if (lowerTitle.StartsWith("imdb:") || lowerTitle.StartsWith("imdbid:"))
{
@@ -387,7 +389,7 @@ namespace NzbDrone.Core.MetadataSource.SkyHook
}
}
var searchTerm = lowerTitle.Replace("_", "+").Replace(" ", "+").Replace(".", "+");
var searchTerm = parserTitle.Replace("_", "+").Replace(" ", "+").Replace(".", "+");
var firstChar = searchTerm.First();