From d695c578052b64613f940295ea65d863ff536033 Mon Sep 17 00:00:00 2001 From: Audric Ackermann Date: Thu, 28 May 2020 09:54:51 +1000 Subject: [PATCH] wait to delete secondaryDevice conversation after unpairing --- js/background.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/js/background.js b/js/background.js index e8554d912..f88625707 100644 --- a/js/background.js +++ b/js/background.js @@ -1431,9 +1431,11 @@ // TODO: we should ensure the message was sent and retry automatically if not await libloki.api.sendUnpairingMessageToSecondary(pubKey); // Remove all traces of the device - ConversationController.deleteContact(pubKey); - Whisper.events.trigger('refreshLinkedDeviceList'); - callback(); + setTimeout(() => { + ConversationController.deleteContact(pubKey); + Whisper.events.trigger('refreshLinkedDeviceList'); + callback(); + }, 1000); }); }