1
0
mirror of https://github.com/Radarr/Radarr.git synced 2026-04-25 22:37:27 -04:00

Fixed: Parse EN from release titles as English

This commit is contained in:
Bogdan
2025-04-07 15:32:26 +03:00
parent d9704a999d
commit 29ca18d3f3
2 changed files with 10 additions and 1 deletions
+7 -1
View File
@@ -41,7 +41,8 @@ namespace NzbDrone.Core.Parser
(?<original>\b(?:orig|original)\b)",
RegexOptions.IgnoreCase | RegexOptions.Compiled | RegexOptions.IgnorePatternWhitespace);
private static readonly Regex CaseSensitiveLanguageRegex = new Regex(@"(?:(?i)(?<!SUB[\W|_|^]))(?:(?<lithuanian>\bLT\b)|
private static readonly Regex CaseSensitiveLanguageRegex = new Regex(@"(?:(?i)(?<!SUB[\W|_|^]))(?:(?<english>\bEN\b)|
(?<lithuanian>\bLT\b)|
(?<czech>\bCZ\b)|
(?<polish>\bPL\b)|
(?<bulgarian>\bBG\b)|
@@ -259,6 +260,11 @@ namespace NzbDrone.Core.Parser
foreach (Match match in caseSensitiveMatches)
{
if (match.Groups["english"].Captures.Any())
{
languages.Add(Language.English);
}
if (match.Groups["lithuanian"].Captures.Any())
{
languages.Add(Language.Lithuanian);