Merge pull request #82 from Mikunj/fix/friend-status

Bug fixes
pull/83/head
Beaudan Campbell-Brown 6 years ago committed by GitHub
commit 94d3ae7b5d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1876,6 +1876,12 @@
timestamp: null,
active_at: null,
});
// Reset our friend status if we're not friends
if (!this.isFriend()) {
this.set({ friendRequestStatus: FriendRequestStatusEnum.none });
}
await window.Signal.Data.updateConversation(this.id, this.attributes, {
Conversation: Whisper.Conversation,
});

@ -1402,7 +1402,7 @@
message.set({ friendStatus: 'accepted' });
await conversation.onFriendRequestAccepted();
window.libloki.sendFriendRequestAccepted(message.get('source'));
} else if (conversation.isFriendRequestStatusNone()) {
} else if (!conversation.isFriend()) {
await conversation.onFriendRequestReceived();
}
} else {

@ -121,7 +121,7 @@ OutgoingMessage.prototype = {
}
return builder.processPreKey(device).then(async () => {
// TODO: only remove the keys that were used above!
await window.libloki.removePreKeyBundleForNumber(number);
await window.libloki.removeContactPreKeyBundle(number);
return true;
}
).catch(error => {

Loading…
Cancel
Save