Mark contact as registered when receiving message

This commit is contained in:
Fedor Indutny 2021-04-29 14:24:55 -07:00 committed by GitHub
parent dfbbd16e50
commit 8ac2d8fcec
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 0 deletions

View File

@ -3262,6 +3262,11 @@ export class MessageModel extends window.Backbone.Model<MessageAttributesType> {
const conversationId = message.get('conversationId');
const GROUP_TYPES = window.textsecure.protobuf.GroupContext.Type;
const fromContact = this.getContact();
if (fromContact) {
fromContact.setRegistered();
}
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
const conversation = window.ConversationController.get(conversationId)!;
return conversation.queueJob(async () => {