mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-01-15 23:58:57 +00:00
fix SA1513/SA1516
This commit is contained in:
@@ -28,7 +28,9 @@ namespace MediaBrowser.Controller.Entities
|
||||
public string PrimaryVersionId { get; set; }
|
||||
|
||||
public string[] AdditionalParts { get; set; }
|
||||
|
||||
public string[] LocalAlternateVersions { get; set; }
|
||||
|
||||
public LinkedChild[] LinkedAlternateVersions { get; set; }
|
||||
|
||||
[JsonIgnore]
|
||||
@@ -52,15 +54,18 @@ namespace MediaBrowser.Controller.Entities
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (extraType.Value == Model.Entities.ExtraType.ThemeVideo)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (extraType.Value == Model.Entities.ExtraType.Trailer)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -196,6 +201,7 @@ namespace MediaBrowser.Controller.Entities
|
||||
return video.MediaSourceCount;
|
||||
}
|
||||
}
|
||||
|
||||
return LinkedAlternateVersions.Length + LocalAlternateVersions.Length + 1;
|
||||
}
|
||||
}
|
||||
@@ -390,11 +396,13 @@ namespace MediaBrowser.Controller.Entities
|
||||
AdditionalParts = newVideo.AdditionalParts;
|
||||
updateType |= ItemUpdateType.MetadataImport;
|
||||
}
|
||||
|
||||
if (!LocalAlternateVersions.SequenceEqual(newVideo.LocalAlternateVersions, StringComparer.Ordinal))
|
||||
{
|
||||
LocalAlternateVersions = newVideo.LocalAlternateVersions;
|
||||
updateType |= ItemUpdateType.MetadataImport;
|
||||
}
|
||||
|
||||
if (VideoType != newVideo.VideoType)
|
||||
{
|
||||
VideoType = newVideo.VideoType;
|
||||
@@ -416,6 +424,7 @@ namespace MediaBrowser.Controller.Entities
|
||||
.Select(i => i.FullName)
|
||||
.ToArray();
|
||||
}
|
||||
|
||||
if (videoType == VideoType.BluRay)
|
||||
{
|
||||
return FileSystem.GetFiles(rootPath, new[] { ".m2ts" }, false, true)
|
||||
@@ -425,6 +434,7 @@ namespace MediaBrowser.Controller.Entities
|
||||
.Select(i => i.FullName)
|
||||
.ToArray();
|
||||
}
|
||||
|
||||
return Array.Empty<string>();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user