mirror of https://github.com/jellyfin/jellyfin.git
simplify if
This commit is contained in:
parent
7689990ad1
commit
c76026600e
|
@ -225,13 +225,8 @@ namespace MediaBrowser.Providers.TV
|
||||||
var season = await CreateSeasonAsync(series, seasonName, seasonNumber, cancellationToken).ConfigureAwait(false);
|
var season = await CreateSeasonAsync(series, seasonName, seasonNumber, cancellationToken).ConfigureAwait(false);
|
||||||
series.AddChild(season);
|
series.AddChild(season);
|
||||||
}
|
}
|
||||||
else
|
else if (!string.Equals(existingSeason.Name, seasonName, StringComparison.Ordinal))
|
||||||
{
|
{
|
||||||
if (string.Equals(existingSeason.Name, seasonName, StringComparison.Ordinal))
|
|
||||||
{
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
existingSeason.Name = seasonName;
|
existingSeason.Name = seasonName;
|
||||||
await existingSeason.UpdateToRepositoryAsync(ItemUpdateType.MetadataEdit, cancellationToken).ConfigureAwait(false);
|
await existingSeason.UpdateToRepositoryAsync(ItemUpdateType.MetadataEdit, cancellationToken).ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue