mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2025-09-19 18:11:51 +02:00
Compares room messages by reference.
This commit is contained in:
@@ -295,7 +295,7 @@ class User(val pubkeyHex: String) {
|
|||||||
fun hasSentMessagesTo(user: User?): Boolean {
|
fun hasSentMessagesTo(user: User?): Boolean {
|
||||||
val messagesToUser = privateChatrooms[user] ?: return false
|
val messagesToUser = privateChatrooms[user] ?: return false
|
||||||
|
|
||||||
return messagesToUser.roomMessages.any { this == it.author }
|
return messagesToUser.roomMessages.any { this === it.author }
|
||||||
}
|
}
|
||||||
|
|
||||||
fun hasReport(loggedIn: User, type: ReportEvent.ReportType): Boolean {
|
fun hasReport(loggedIn: User, type: ReportEvent.ReportType): Boolean {
|
||||||
|
Reference in New Issue
Block a user