mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
[DatItem] Make logic more readable in merge
This commit is contained in:
@@ -689,8 +689,12 @@ namespace SabreTools.Library.DatItems
|
||||
}
|
||||
|
||||
// If it's the first rom in the list, don't touch it
|
||||
if (outfiles.Count != 0)
|
||||
if (outfiles.Count == 0)
|
||||
{
|
||||
outfiles.Add(file);
|
||||
continue;
|
||||
}
|
||||
|
||||
// Check if the rom is a duplicate
|
||||
DupeType dupetype = 0x00;
|
||||
DatItem saveditem = new Rom();
|
||||
@@ -792,11 +796,6 @@ namespace SabreTools.Library.DatItems
|
||||
outfiles.Insert(pos, saveditem);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
outfiles.Add(file);
|
||||
}
|
||||
}
|
||||
|
||||
// Then return the result
|
||||
return outfiles;
|
||||
|
||||
Reference in New Issue
Block a user