From a7aaf246aed6af736e29b7fd46640dcfff724641 Mon Sep 17 00:00:00 2001 From: Emmm Monster <58943012+emmmx@users.noreply.github.com> Date: Thu, 27 May 2021 19:38:42 +0800 Subject: [PATCH] fix: .vpr/.kgm fail in worker --- src/decrypt/kgm.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/decrypt/kgm.ts b/src/decrypt/kgm.ts index 4a1eedd..f12e0df 100644 --- a/src/decrypt/kgm.ts +++ b/src/decrypt/kgm.ts @@ -22,7 +22,7 @@ const VprMaskDiff = [ export async function Decrypt(file: File, raw_filename: string, raw_ext: string): Promise { - if (window?.location?.protocol === "file:") { + if (self.location.protocol === "file:") { throw Error("请使用 CLI版本 进行解锁") }