mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-24 12:19:41 +00:00
Divorce identity wipe from tryAgain functions
We'd like to live in a world where we can retry all the pending conflicts in a conversation as a batch, which means we don't want to wipe the identity key before processing each message. Thus, remove that step from these handlers and encapsulate in a method on the conversation model.
This commit is contained in:
@@ -47,6 +47,15 @@
|
||||
if (this.collection) {
|
||||
return this.collection.conversation.contactCollection.get(this.get('source'));
|
||||
}
|
||||
},
|
||||
isOutgoing: function() {
|
||||
return this.get('type') === 'outgoing';
|
||||
},
|
||||
getKeyConflict: function() {
|
||||
return _.find(this.get('errors'), function(e) {
|
||||
return ( e.name === 'IncomingIdentityKeyError' ||
|
||||
e.name === 'OutgoingIdentityKeyError');
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user