Add FindByName to IsoLanguage
This commit is contained in:
parent
4fe79e9a4e
commit
7238100145
|
@ -1,3 +1,4 @@
|
||||||
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using NzbDrone.Core.Languages;
|
using NzbDrone.Core.Languages;
|
||||||
|
@ -107,5 +108,10 @@ namespace NzbDrone.Core.Parser
|
||||||
{
|
{
|
||||||
return All.FirstOrDefault(l => l.Language == language);
|
return All.FirstOrDefault(l => l.Language == language);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static IsoLanguage FindByName(string name)
|
||||||
|
{
|
||||||
|
return All.FirstOrDefault(l => l.Language.Name.Equals(name, StringComparison.InvariantCultureIgnoreCase));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue