1
0
mirror of https://github.com/kkapsner/CanvasBlocker synced 2024-12-22 12:50:36 +01:00

Added loading of the current settings in the frame script.

This commit is contained in:
kkapsner 2017-07-18 16:17:19 +02:00
parent bec157391d
commit 3c47eaf97f

View File

@ -149,6 +149,13 @@
}
});
browser.storage.local.get().then(function(data){
Object.keys(data).forEach(function(key){
log("loaded setting:", key, ":", data[key]);
settings[key] = data[key];
});
});
log("register listener for settings changes");
browser.storage.onChanged.addListener(function(change, area){
if (area === "local"){