diff --git a/CHANGELOG b/CHANGELOG index 4f7f90a..6b1927b 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,6 +1,10 @@ +0.3.9 (04-11-2017) +========================= +- Removed incorrect timeout waiting on init + 0.3.8 (01-11-2017) ========================= -- Use browser.local.storage instead of localStorage +- Use browser.storage.local instead of localStorage - Switched some functions to promise 0.3.7 (22-10-2017) diff --git a/keepassxc-browser/background/event.js b/keepassxc-browser/background/event.js index bf9b5d2..264a70a 100644 --- a/keepassxc-browser/background/event.js +++ b/keepassxc-browser/background/event.js @@ -130,6 +130,11 @@ kpxcEvent.onSaveSettings = function(callback, tab, settings) { kpxcEvent.onGetStatus = function(callback, tab) { keepass.testAssociation((response) => { + if (!response) { + kpxcEvent.showStatus(false, tab, callback); + return; + } + keepass.isConfigured().then((configured) => { kpxcEvent.showStatus(configured, tab, callback); }); diff --git a/keepassxc-browser/background/init.js b/keepassxc-browser/background/init.js index 127f4d6..a57cad3 100644 --- a/keepassxc-browser/background/init.js +++ b/keepassxc-browser/background/init.js @@ -3,7 +3,7 @@ keepass.migrateKeyRing().then(() => { page.initOpenedTabs().then(() => { keepass.connectToNative(); keepass.generateNewKeyPair(); - keepass.changePublicKeys(null, keepass.messageTimeout).then((pkRes) => { + keepass.changePublicKeys(null).then((pkRes) => { keepass.getDatabaseHash((gdRes) => {}, null); }); }); diff --git a/keepassxc-browser/background/page.js b/keepassxc-browser/background/page.js index 8e868d3..7aba064 100644 --- a/keepassxc-browser/background/page.js +++ b/keepassxc-browser/background/page.js @@ -54,6 +54,7 @@ page.initOpenedTabs = function() { // set initial tab-ID browser.tabs.query({ "active": true, "currentWindow": true }).then((tabs) => { if (tabs.length === 0) { + resolve(); return; // For example: only the background devtools or a popup are opened } page.currentTabId = tabs[0].id;