Simplify Equals() logic in BossFightEnum

rabi_display
wcko87 8 years ago
parent ce1b59d51f
commit d2c4234943
  1. 12
      rabi_splitter_WPF/BossFightEnum.cs

@ -88,16 +88,8 @@ namespace rabi_splitter_WPF
public override bool Equals(object obj)
{
var otherValue = obj as BossFight;
if (otherValue == null)
{
return false;
}
var typeMatches = GetType().Equals(obj.GetType());
var valueMatches = _value.Equals(otherValue.Value);
return typeMatches && valueMatches;
if (otherValue == null) return false;
return _value.Equals(otherValue.Value);
}
public override int GetHashCode()

Loading…
Cancel
Save