1
0
mirror of https://github.com/Radarr/Radarr.git synced 2024-09-11 03:52:33 +02:00

Fixed: Queue error for language custom format on unknown items

This commit is contained in:
Qstick 2023-03-29 19:21:35 -05:00
parent d35c6683e9
commit 7d9183ef12

View File

@ -34,9 +34,10 @@ public class LanguageSpecification : CustomFormatSpecificationBase
protected override bool IsSatisfiedByWithoutNegate(CustomFormatInput input)
{
var comparedLanguage = input.MovieInfo != null && Value == Language.Original.Id && input.Movie.MovieMetadata.Value.OriginalLanguage != Language.Unknown
var comparedLanguage = input.MovieInfo != null && input.Movie != null && Value == Language.Original.Id && input.Movie.MovieMetadata.Value.OriginalLanguage != Language.Unknown
? input.Movie.MovieMetadata.Value.OriginalLanguage
: (Language)Value;
return input?.Languages?.Contains(comparedLanguage) ?? false;
}