fix(message-service): ignore new messages in 1-1 when not a contact
Fixes #6639
This commit is contained in:
parent
0e7e541a62
commit
d18daccf4a
|
@ -169,6 +169,11 @@ QtObject:
|
||||||
error "error: new message with an unknown chat type received", chatId=chats[i].id
|
error "error: new message with an unknown chat type received", chatId=chats[i].id
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
# Ignore 1-1 chats for which we are not contact
|
||||||
|
if (chats[i].chatType == ChatType.OneToOne and not self.contactService.getContactById(chats[i].id).isContact):
|
||||||
|
continue
|
||||||
|
|
||||||
|
|
||||||
var chatMessages: seq[MessageDto]
|
var chatMessages: seq[MessageDto]
|
||||||
for msg in messages:
|
for msg in messages:
|
||||||
if (msg.localChatId == chats[i].id):
|
if (msg.localChatId == chats[i].id):
|
||||||
|
|
Loading…
Reference in New Issue