Commit 756e8b53 authored by Him188's avatar Him188

Improve `equals`

parent 9f7dec26
...@@ -300,7 +300,7 @@ internal class MemberImpl( ...@@ -300,7 +300,7 @@ internal class MemberImpl(
@Suppress("DuplicatedCode") @Suppress("DuplicatedCode")
override fun equals(other: Any?): Boolean { // 不要删除. trust me override fun equals(other: Any?): Boolean { // 不要删除. trust me
if (this === other) return true if (this === other) return true
if (other !is Contact) return false if (other !is Member) return false
if (this::class != other::class) return false if (this::class != other::class) return false
return this.id == other.id && this.bot == other.bot return this.id == other.id && this.bot == other.bot
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment