From 6edd43fee62de5e3974bab08178cac7f724d4a94 Mon Sep 17 00:00:00 2001 From: Bayu Satiyo Date: Wed, 6 Dec 2023 19:04:57 +0700 Subject: [PATCH] Add bypass for link1s.com FastForwardTeam/FastForward#40 Signed-off-by: Bayu Satiyo --- src/bypasses/link1s.js | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 src/bypasses/link1s.js diff --git a/src/bypasses/link1s.js b/src/bypasses/link1s.js new file mode 100644 index 00000000..5f1419ac --- /dev/null +++ b/src/bypasses/link1s.js @@ -0,0 +1,20 @@ +import BypassDefinition from './BypassDefinition.js' + +export default class Link1s extends BypassDefinition { + constructor () { + super() + } + execute () { + this.helpers.awaitElement('#link1s[href]', a => + this.helpers.safelyNavigate(a.href) + ) + this.helpers.awaitElement('#link1s-snp button', b => b.click()) + this.helpers.awaitElement('.skip-ad a.btn', a => { + setInterval(() => { + this.helpers.safelyNavigate(a.href) + }, 50) // wait the url to be updated + }) + } +} + +export const matches = ['link1s.com', 'anhdep24.com']