Update Emby.Server.Implementations/Localization/LocalizationManager.cs

Co-authored-by: theguymadmax <theguymadmax@proton.me>
This commit is contained in:
Tim Eisele
2026-03-26 10:06:50 +01:00
committed by GitHub
parent d5fb6f99ef
commit f793acc1aa

View File

@@ -320,6 +320,14 @@ namespace Emby.Server.Implementations.Localization
{
return value;
}
if (ratingsDictionary is not null && rating.Length > countryCode.Length
&& rating.StartsWith(countryCode, StringComparison.OrdinalIgnoreCase)
&& (rating[countryCode.Length] == '-' || rating[countryCode.Length] == ':')
&& ratingsDictionary.TryGetValue(rating[(countryCode.Length + 1)..].Trim(), out var normalizedValue))
{
return normalizedValue;
}
}
else
{