Fix unconditional null in `Equals` implementation

This commit is contained in:
Dean Herbert 2022-03-08 23:25:51 +09:00
parent c867068cae
commit 512536f5fe
1 changed files with 1 additions and 1 deletions

View File

@ -64,7 +64,7 @@ public virtual bool Equals(Message other)
if (ReferenceEquals(null, other)) return false;
if (ReferenceEquals(this, other)) return true;
return Id.HasValue && Id == other?.Id;
return Id.HasValue && Id == other.Id;
}
// ReSharper disable once ImpureMethodCallOnReadonlyValueField