Fixed: Dedupe titles to avoid similar search requests
This commit is contained in:
parent
37c4647f24
commit
ffdb08cfe6
|
@ -63,7 +63,9 @@ namespace NzbDrone.Core.DataAugmentation.Scene
|
|||
sceneSeasonNumbers.Contains(n.SceneSeasonNumber ?? -1) ||
|
||||
((n.SeasonNumber ?? -1) == -1 && (n.SceneSeasonNumber ?? -1) == -1 && n.SceneOrigin != "tvdb"))
|
||||
.Where(n => IsEnglish(n.SearchTerm))
|
||||
.Select(n => n.SearchTerm).Distinct().ToList();
|
||||
.Select(n => n.SearchTerm)
|
||||
.Distinct(StringComparer.InvariantCultureIgnoreCase)
|
||||
.ToList();
|
||||
|
||||
return names;
|
||||
}
|
||||
|
|
|
@ -193,7 +193,7 @@ namespace NzbDrone.Core.IndexerSearch
|
|||
foreach (var item in dict)
|
||||
{
|
||||
item.Value.Episodes = item.Value.Episodes.Distinct().ToList();
|
||||
item.Value.SceneTitles = item.Value.SceneTitles.Distinct().ToList();
|
||||
item.Value.SceneTitles = item.Value.SceneTitles.Distinct(StringComparer.InvariantCultureIgnoreCase).ToList();
|
||||
}
|
||||
|
||||
return dict.Values.ToList();
|
||||
|
@ -221,7 +221,7 @@ namespace NzbDrone.Core.IndexerSearch
|
|||
|
||||
foreach (var item in dict)
|
||||
{
|
||||
item.Value.SceneTitles = item.Value.SceneTitles.Distinct().ToList();
|
||||
item.Value.SceneTitles = item.Value.SceneTitles.Distinct(StringComparer.InvariantCultureIgnoreCase).ToList();
|
||||
}
|
||||
|
||||
return dict.Values.ToList();
|
||||
|
@ -463,7 +463,7 @@ namespace NzbDrone.Core.IndexerSearch
|
|||
spec.UserInvokedSearch = userInvokedSearch;
|
||||
spec.InteractiveSearch = interactiveSearch;
|
||||
|
||||
if (!spec.SceneTitles.Contains(series.Title))
|
||||
if (!spec.SceneTitles.Contains(series.Title, StringComparer.InvariantCultureIgnoreCase))
|
||||
{
|
||||
spec.SceneTitles.Add(series.Title);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue