From 5c7ca7f860d085ca321b647a2de977fa66939589 Mon Sep 17 00:00:00 2001 From: achmizs Date: Wed, 30 Jan 2019 23:59:19 -0500 Subject: [PATCH] Cleared up name collision --- contentScript.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/contentScript.js b/contentScript.js index 6544722..40defe5 100644 --- a/contentScript.js +++ b/contentScript.js @@ -8,13 +8,13 @@ window.onload = () => { function killStickyIfMatch(result) { if (typeof result.matchingPatterns == "undefined") return; - var killSticky = false; + var shouldKillSticky = false; let matchingPatterns = result.mode == "whitelist" ? [ ".*" ] : result.matchingPatterns.split("\n"); for (let pattern of matchingPatterns) { if (location.href.match(new RegExp(pattern))) { - killSticky = true; + shouldKillSticky = true; break; } } @@ -24,10 +24,10 @@ function killStickyIfMatch(result) { [ ]; for (let pattern of exclusionPatterns) { if (location.href.match(new RegExp(pattern))) { - killSticky = false; + shouldKillSticky = false; break; } } - if (!killSticky) return; + if (!shouldKillSticky) return; killSticky(); }