Fixed: Manual import when no reprocessing items after selecting series and season

This commit is contained in:
Mark McDowall 2022-12-17 21:25:13 -08:00
parent b8714d80a1
commit fc8e6d6f02
1 changed files with 3 additions and 2 deletions

View File

@ -44,8 +44,9 @@ namespace Sonarr.Api.V3.ManualImport
item.Episodes = processedItem.Episodes.ToResource();
item.Rejections = processedItem.Rejections;
// Only set the language/quality if they're unknown
if (item.Languages.Single() == Language.Unknown)
// Only set the language/quality if they're unknown and languages were returned.
// Languages won't be returned when reprocessing if the season/episode isn't filled in yet and we don't want to return no languages to the client.
if ((item.Languages.SingleOrDefault() ?? Language.Unknown) == Language.Unknown && processedItem.Languages.Any())
{
item.Languages = processedItem.Languages;
}