Fix issue with CHD-only dats

This commit is contained in:
Matt Nadareski
2020-07-19 13:42:07 -07:00
parent 75490b7e13
commit 4596c7b299
3 changed files with 50 additions and 31 deletions

View File

@@ -1116,8 +1116,10 @@ namespace SabreTools.Library.DatItems
// Then deduplicate them by checking to see if data matches previous saved roms
int nodumpCount = 0;
foreach (DatItem file in infiles)
for (int f = 0; f < infiles.Count; f++)
{
DatItem file = infiles[f];
// If we don't have a Rom or a Disk, we skip checking for duplicates
if (file.ItemType != ItemType.Rom && file.ItemType != ItemType.Disk)
continue;