mirror of
https://github.com/SabreTools/SabreTools.Serialization.git
synced 2026-09-21 22:35:06 +00:00
Allow sizeless ROMs if there's a SHA-1 or SHA-256
This commit is contained in:
@@ -684,6 +684,14 @@ namespace SabreTools.Metadata.DatFiles
|
||||
if (rom.CRC32 != "null")
|
||||
return rom;
|
||||
|
||||
// If the item has a SHA-1 but no size
|
||||
if (rom.Size is null && rom.SHA1 is not null)
|
||||
return rom;
|
||||
|
||||
// If the item has a SHA-256 but no size
|
||||
if (rom.Size is null && rom.SHA256 is not null)
|
||||
return rom;
|
||||
|
||||
// If the Rom has "null" characteristics, ensure all fields
|
||||
rom.Name = rom.Name == "null" ? "-" : rom.Name;
|
||||
rom.Size = 0;
|
||||
|
||||
Reference in New Issue
Block a user