1
0
mirror of https://github.com/Radarr/Radarr.git synced 2024-11-04 10:02:40 +01:00

Fix spelling "Use languages from Torznab/Newznab attributes if given"

(cherry picked from commit de3bfb7c5ab03e527dca1be3ef4a664dce266db6)
This commit is contained in:
Bogdan 2023-05-21 19:05:18 +03:00
parent b7be2c1d6e
commit e9dcef34d4
2 changed files with 8 additions and 8 deletions

View File

@ -107,16 +107,16 @@ protected override string GetCommentUrl(XElement item)
protected override List<Language> GetLanguages(XElement item) protected override List<Language> GetLanguages(XElement item)
{ {
var languges = TryGetMultipleNewznabAttributes(item, "language"); var languages = TryGetMultipleNewznabAttributes(item, "language");
var results = new List<Language>(); var results = new List<Language>();
// Try to find <language> elements for some indexers that suck at following the rules. // Try to find <language> elements for some indexers that suck at following the rules.
if (languges.Count == 0) if (languages.Count == 0)
{ {
languges = item.Elements("language").Select(e => e.Value).ToList(); languages = item.Elements("language").Select(e => e.Value).ToList();
} }
foreach (var language in languges) foreach (var language in languages)
{ {
var mappedLanguage = IsoLanguages.FindByName(language)?.Language ?? null; var mappedLanguage = IsoLanguages.FindByName(language)?.Language ?? null;

View File

@ -103,16 +103,16 @@ protected override string GetCommentUrl(XElement item)
protected override List<Language> GetLanguages(XElement item) protected override List<Language> GetLanguages(XElement item)
{ {
var languges = TryGetMultipleTorznabAttributes(item, "language"); var languages = TryGetMultipleTorznabAttributes(item, "language");
var results = new List<Language>(); var results = new List<Language>();
// Try to find <language> elements for some indexers that suck at following the rules. // Try to find <language> elements for some indexers that suck at following the rules.
if (languges.Count == 0) if (languages.Count == 0)
{ {
languges = item.Elements("language").Select(e => e.Value).ToList(); languages = item.Elements("language").Select(e => e.Value).ToList();
} }
foreach (var language in languges) foreach (var language in languages)
{ {
var mappedLanguage = IsoLanguages.FindByName(language)?.Language ?? null; var mappedLanguage = IsoLanguages.FindByName(language)?.Language ?? null;