diff --git a/js/libtextsecure.js b/js/libtextsecure.js index 8b85e8c94..a7ac81d83 100644 --- a/js/libtextsecure.js +++ b/js/libtextsecure.js @@ -36584,6 +36584,10 @@ var TextSecureServer = (function() { textsecure.storage.remove('device_name'); textsecure.storage.remove('regionCode'); + // remove our own identity key, which may have changed + // if we're relinking after a reinstall on the master device + textsecure.storage.axolotl.removeIdentityKey(number); + textsecure.storage.put('identityKey', identityKeyPair); textsecure.storage.put('signaling_key', signalingKey); textsecure.storage.put('password', password); diff --git a/libtextsecure/account_manager.js b/libtextsecure/account_manager.js index 471972489..69a13c608 100644 --- a/libtextsecure/account_manager.js +++ b/libtextsecure/account_manager.js @@ -106,6 +106,10 @@ textsecure.storage.remove('device_name'); textsecure.storage.remove('regionCode'); + // remove our own identity key, which may have changed + // if we're relinking after a reinstall on the master device + textsecure.storage.axolotl.removeIdentityKey(number); + textsecure.storage.put('identityKey', identityKeyPair); textsecure.storage.put('signaling_key', signalingKey); textsecure.storage.put('password', password);