using System.Collections.Generic; namespace IRCStates { public class ChannelUser { public List Modes { get; } = new List(); private bool Equals(ChannelUser other) { return other != null && Equals(Modes, other.Modes); } public override bool Equals(object obj) { if (ReferenceEquals(null, obj)) return false; if (ReferenceEquals(this, obj)) return true; return obj.GetType() == GetType() && Equals((ChannelUser) obj); } public override int GetHashCode() { return Modes != null ? Modes.GetHashCode() : 0; } } }