Plumb keys into outgoing conflicts

This commit is contained in:
lilia 2015-07-20 16:13:17 -07:00
parent 0815a96c1d
commit c28b5408ab
4 changed files with 20 additions and 12 deletions

View file

@ -57,7 +57,7 @@
IncomingIdentityKeyError.prototype = new ReplayableError();
IncomingIdentityKeyError.prototype.constructor = IncomingIdentityKeyError;
function OutgoingIdentityKeyError(number, message, timestamp) {
function OutgoingIdentityKeyError(number, message, timestamp, identityKey) {
ReplayableError.call(this, {
functionCode : Type.SEND_MESSAGE,
args : [number, message, timestamp]
@ -65,6 +65,7 @@
this.name = 'OutgoingIdentityKeyError';
this.message = "The identity of the destination has changed. This may be malicious, or the destination may have simply reinstalled.";
this.number = number.split('.')[0];
this.identityKey = identityKey;
}
OutgoingIdentityKeyError.prototype = new ReplayableError();
OutgoingIdentityKeyError.prototype.constructor = OutgoingIdentityKeyError;