Skip to content

Commit 7cab34c

Browse files
committed
fix: prevent Ad-Shield intended breakage because tinyShield pass its setTimeout usage
1 parent 5bc5ede commit 7cab34c

File tree

3 files changed

+6
-2
lines changed

3 files changed

+6
-2
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@filteringdev/tinyshield",
3-
"version": "2.0.1",
3+
"version": "2.0.2",
44
"description": "",
55
"type": "module",
66
"scripts": {

sources/banner.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
// @downloadURL https://cdn.jsdelivr.net/npm/@filteringdev/tinyshield@latest/dist/tinyShield.user.js
99
// @license MIT
1010
//
11-
// @version 2.0.1
11+
// @version 2.0.2
1212
// @author PiQuark6046 and contributors
1313
//
1414
// @match *://ygosu.com/*

sources/src/index.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,10 @@ let ASTimerRegExps: RegExp[][] = [[
8383
/function *\( *\) *{ *const *[a-zA-Z0-9]+ *= *[a-zA-Z0-9]+ *; *for *\( *var *[a-zA-Z0-9]+ *= *[a-zA-Z0-9]+ *\[ *[a-zA-Z0-9]+ *\( *0x[a-f0-9]+ *\) *\] *,/,
8484
/ *,[a-zA-Z0-9]+ *= *new *Array *\( *[A-Za-z0-9]+ *\) *, *[A-Za-z0-9]+ *= *0x[a-f0-9]+ *; *[A-Za-z0-9]+ *< *[A-Za-z0-9]+ *; *[A-Za-z0-9]+ *\+\+ *\)/,
8585
/\) *\? *[A-Za-z0-9]+ *\[ *[A-Za-z0-9]+ *\( *0x[a-f0-9]+ *\) *\] *\[ *[A-Za-z0-9]+ *\( *0x[a-f0-9]+ *\) *\] * *\([A-Za-z0-9]+ *, *\.\.\. *[A-Za-z0-9]+ *\) *: *void *0x[a-f0-9]+/
86+
], [
87+
/async *\( *\) *=> *{ *const *[A-Za-z0-9]+ *= *[A-Za-z0-9]+ *; *await *[A-Za-z0-9]+ *\( *\)/,
88+
/; *await *[A-Za-z0-9]+ *\( *\) *, *[A-Za-z0-9]+ *\( *! *1 *, *new *Error *\( *[A-Za-z0-9]+ *\( *[0-9a-f]+ *\) *\) *\) *}/,
89+
/ *\) *\) *\) *}/
8690
]]
8791
Win.setTimeout = new Proxy(Win.setTimeout, {
8892
apply(Target: typeof Win.setTimeout, ThisArg: undefined, Args: Parameters<typeof setTimeout>) {

0 commit comments

Comments
 (0)