aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorNDevTK <[email protected]>2022-05-19 23:17:18 +0100
committerAjay <[email protected]>2022-06-02 21:37:21 -0400
commitbfadb1373a55125fc8d7876e7f1cae12fdd8604a (patch)
tree79c56cf26d0f5aa3cbadc055d86d8886dbb2d648
parenta7956aacf92dadbebb92eb68fbd7ce4603934044 (diff)
downloadSponsorBlock-bfadb1373a55125fc8d7876e7f1cae12fdd8604a.tar.gz
SponsorBlock-bfadb1373a55125fc8d7876e7f1cae12fdd8604a.zip
Add comment
-rw-r--r--src/popup.ts1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/popup.ts b/src/popup.ts
index e97559cc..32c4424a 100644
--- a/src/popup.ts
+++ b/src/popup.ts
@@ -43,6 +43,7 @@ class MessageHandler {
let allowPopup = (window === window.top);
+// To prevent clickjacking
window.onmessage = async e => {
if (e.source !== window.parent) return
if (e.origin.endsWith('.youtube.com')) return allowPopup = true;