Fix listener leaking

This commit is contained in:
varjolintu 2018-03-08 17:16:39 +02:00
parent 063c048625
commit 5d77966605

View file

@ -1172,7 +1172,7 @@ cip.detectDatabaseChange = function() {
browser.runtime.sendMessage({
action: 'check_databasehash'
}).then((response) => {
if (response.new === 'no-hash') {
if (response.new === 'no-hash' && response.old !== 'no-hash') {
cipEvents.clearCredentials();
browser.runtime.sendMessage({