diff --git a/content_script.js b/content_script.js index ff72c91..502af2d 100644 --- a/content_script.js +++ b/content_script.js @@ -35,11 +35,13 @@ function processMutations(mutationList, observer) { let clickThroughForms; let observer = new MutationObserver(processMutations); const addObserver = () => { - browser.storage.sync.get('autocontinue').then(v => { + browser.storage.sync.get(['autocontinue', 'enable']).then(v => { clickThroughForms = !!v.autocontinue; - observer.observe(document.body, { - childList: true, subtree: true - }) + if (!!v.enable) { + observer.observe(document.body, { + childList: true, subtree: true + }) + } }) }; diff --git a/options/index.html b/options/index.html index 22520ee..bcb8e57 100644 --- a/options/index.html +++ b/options/index.html @@ -9,6 +9,10 @@
+