From 4c784e6546167d64954ba0253f4d93adc6d7129f Mon Sep 17 00:00:00 2001 From: Mimi <1119186082@qq.com> Date: Sun, 29 Dec 2019 16:13:57 +0800 Subject: [PATCH] Replace the regex with an empty function object --- waifu-tips.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/waifu-tips.js b/waifu-tips.js index 65b61a5..2d39b6d 100755 --- a/waifu-tips.js +++ b/waifu-tips.js @@ -51,11 +51,10 @@ function loadWidget(waifuPath, apiPath) { $("#waifu-toggle").show().animate({ "margin-left": -50 }, 1000); }); }); - var re = /Live2D Widget/; - console.log(re); - re.toString = () => { + var devtools = () => {}; + console.log("%c", devtools); + devtools.toString = () => { showMessage("哈哈,你打开了控制台,是想要看看我的小秘密吗?", 6000, 9); - return ""; }; window.addEventListener("copy", () => { showMessage("你都复制了些什么呀,转载要记得加上出处哦!", 6000, 9);