mirror of
https://github.com/oxen-io/session-desktop.git
synced 2023-12-14 02:12:57 +01:00
Prevent prekeys to be deleted when re-sending pairing request
This commit is contained in:
parent
6cb68d2fc6
commit
3d7548729f
|
@ -444,12 +444,18 @@
|
|||
|
||||
window.log.info('clearing all sessions, prekeys, and signed prekeys');
|
||||
await Promise.all([
|
||||
store.clearPreKeyStore(),
|
||||
store.clearContactPreKeysStore(),
|
||||
store.clearSignedPreKeysStore(),
|
||||
store.clearContactSignedPreKeysStore(),
|
||||
store.clearSessionStore(),
|
||||
]);
|
||||
// During secondary device registration we need to keep our prekeys sent
|
||||
// to other pubkeys
|
||||
if (textsecure.storage.get('secondaryDeviceStatus') !== 'ongoing') {
|
||||
await Promise.all([
|
||||
store.clearPreKeyStore(),
|
||||
store.clearSignedPreKeysStore(),
|
||||
]);
|
||||
}
|
||||
},
|
||||
// Takes the same object returned by generateKeys
|
||||
async confirmKeys(keys) {
|
||||
|
|
Loading…
Reference in a new issue