diff --git a/keepassxc-browser/background/event.js b/keepassxc-browser/background/event.js index de3e6e9..f23ae76 100755 --- a/keepassxc-browser/background/event.js +++ b/keepassxc-browser/background/event.js @@ -74,7 +74,9 @@ kpxcEvent.invoke = function(handler, callback, senderTabId, args, secondTime) { else { console.log('undefined handler for tab ' + tab.id); } - }).catch((e) => {console.log(e);}); + }).catch((e) => { + console.log(e); + }); }; kpxcEvent.onShowNotification = function(callback, tab, message) { @@ -162,13 +164,18 @@ kpxcEvent.onReconnect = function(callback, tab) { if (gdRes) { keepass.testAssociation((response) => { keepass.isConfigured().then((configured) => { + browser.tabs.sendMessage(tab.id, { + action: 'redetect_fields' + }); kpxcEvent.showStatus(configured, tab, callback); - }).catch((e) => {console.log(e);}); + }).catch((e) => { + console.log(e); + }); }, tab); } }, null); }); - }, 2000); + }, 500); }; kpxcEvent.lockDatabase = function(callback, tab) {