Small fixes to Machine

This commit is contained in:
Matt Nadareski
2026-04-04 16:20:42 -04:00
parent 8f82d3a28d
commit 2f72349e7b
2 changed files with 8 additions and 29 deletions

View File

@@ -480,6 +480,11 @@ namespace SabreTools.Data.Models.Metadata
else if (Manufacturer is not null && !Manufacturer.Equals(other.Manufacturer, StringComparison.OrdinalIgnoreCase))
return false;
if ((Name is null) ^ (other.Name is null))
return false;
else if (Name is not null && !Name.Equals(other.Name, StringComparison.OrdinalIgnoreCase))
return false;
if ((Notes is null) ^ (other.Notes is null))
return false;
else if (Notes is not null && !Notes.Equals(other.Notes, StringComparison.OrdinalIgnoreCase))

View File

@@ -468,7 +468,7 @@ namespace SabreTools.Metadata.DatItems
return false;
// Compare internal models
return _internal.EqualTo(otherItem._internal);
return _internal.Equals(otherItem._internal);
}
/// <inheritdoc/>
@@ -483,7 +483,7 @@ namespace SabreTools.Metadata.DatItems
return false;
// Compare internal models
return _internal.EqualTo(otherItem._internal);
return _internal.Equals(otherItem._internal);
}
/// <inheritdoc/>
@@ -493,34 +493,8 @@ namespace SabreTools.Metadata.DatItems
if (other is null)
return false;
// Properties
if ((Description is null) ^ (other.Description is null))
return false;
if (Description is not null && !Description.Equals(other.Description, StringComparison.OrdinalIgnoreCase))
return false;
if (IsBios != other.IsBios)
return false;
if (IsDevice != other.IsDevice)
return false;
if (IsMechanical != other.IsMechanical)
return false;
if ((Name is null) ^ (other.Name is null))
return false;
if (Name is not null && !Name.Equals(other.Name, StringComparison.OrdinalIgnoreCase))
return false;
if (Runnable != other.Runnable)
return false;
if (Supported != other.Supported)
return false;
// Compare internal models
return _internal.EqualTo(other._internal);
return _internal.Equals(other._internal);
}
#endregion