From 1c306df61fc6705de890e1c855ca818368703981 Mon Sep 17 00:00:00 2001 From: lilia Date: Wed, 30 Sep 2015 18:47:41 -0700 Subject: [PATCH] Workaround for #363 Multiple open sessions bug This doesn't solve the problem in the general case, but should at least unbreak registration. // FREEBIE --- js/background.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/js/background.js b/js/background.js index db2aee0f..b080145e 100644 --- a/js/background.js +++ b/js/background.js @@ -101,8 +101,9 @@ messageReceiver.addEventListener('contactsync', onContactSyncComplete); if (firstRun === true && textsecure.storage.user.getDeviceId() != '1') { - textsecure.messaging.sendRequestContactSyncMessage(); - textsecure.messaging.sendRequestGroupSyncMessage(); + textsecure.messaging.sendRequestContactSyncMessage().then(function() { + textsecure.messaging.sendRequestGroupSyncMessage(); + }); } }