diff --git a/MetadataExtractor/Formats/Heif/HeifMetadataReader.cs b/MetadataExtractor/Formats/Heif/HeifMetadataReader.cs index 098bbb68c..349af7486 100644 --- a/MetadataExtractor/Formats/Heif/HeifMetadataReader.cs +++ b/MetadataExtractor/Formats/Heif/HeifMetadataReader.cs @@ -34,8 +34,9 @@ public static IReadOnlyList ReadMetadata(Stream stream) ParseQuickTimeTest(); uint primaryItem = boxes.Descendant()?.PrimaryItem ?? uint.MaxValue; - var itemRefs = (boxes.Descendant()?.Boxes ?? new SingleItemTypeReferenceBox[0]) - .Where(i => i.Type is BoxTypes.ThmbTag or BoxTypes.CdscTag or BoxTypes.MimeTag).ToList(); + var itemRefs = (boxes.Descendant()?.Boxes ?? Array.Empty()) + .Where(i => i.Type is BoxTypes.ThmbTag or BoxTypes.CdscTag or BoxTypes.MimeTag) + .ToList(); ParseImageProperties(); diff --git a/MetadataExtractor/Formats/QuickTime/QuickTimeTypeChecker.cs b/MetadataExtractor/Formats/QuickTime/QuickTimeTypeChecker.cs index fa69b6d71..3d1c54bba 100644 --- a/MetadataExtractor/Formats/QuickTime/QuickTimeTypeChecker.cs +++ b/MetadataExtractor/Formats/QuickTime/QuickTimeTypeChecker.cs @@ -5,7 +5,7 @@ namespace MetadataExtractor.Formats.QuickTime /// Dmitry Shechtman internal sealed class QuickTimeTypeChecker : ITypeChecker { - private static readonly ByteTrie _ftypTrie = new(Util.FileType.QuickTime) + private static readonly ByteTrie _ftypTrie = new(defaultValue: Util.FileType.QuickTime) { // http://www.ftyps.com