From aa7b2b46cf82890a68a868595c69f3df3c6858c4 Mon Sep 17 00:00:00 2001 From: Jack Works <5390719+Jack-Works@users.noreply.github.com> Date: Thu, 10 Oct 2024 15:53:03 +0900 Subject: [PATCH] fix: metamask connect in popup close MF-6422 (#11842) --- packages/mask/.webpack/config.ts | 2 +- packages/mask/.webpack/package-overrides/process.nextTick.mjs | 4 ++++ packages/mask/package.json | 1 - pnpm-lock.yaml | 3 --- 4 files changed, 5 insertions(+), 5 deletions(-) create mode 100644 packages/mask/.webpack/package-overrides/process.nextTick.mjs diff --git a/packages/mask/.webpack/config.ts b/packages/mask/.webpack/config.ts index 7de82c9f2b5f..54aa31e066a0 100644 --- a/packages/mask/.webpack/config.ts +++ b/packages/mask/.webpack/config.ts @@ -212,7 +212,7 @@ export async function createConfiguration(_inputFlags: BuildFlags): Promise { + if (typeof callback !== 'function') throw new TypeError('callback is not a function') + queueMicrotask(() => callback(...rest)) +} diff --git a/packages/mask/package.json b/packages/mask/package.json index fd5f2592e992..4dca289a822c 100644 --- a/packages/mask/package.json +++ b/packages/mask/package.json @@ -125,7 +125,6 @@ "idb": "^8.0.0", "immer": "^10.1.1", "json-stable-stringify": "^1.1.1", - "next-tick": "^1.1.0", "react-avatar-editor": "^13.0.2", "react-draggable": "^4.4.6", "react-highlight-words": "^0.20.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 4ea03d4cc204..d2e3c967183e 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -648,9 +648,6 @@ importers: json-stable-stringify: specifier: ^1.1.1 version: 1.1.1 - next-tick: - specifier: ^1.1.0 - version: 1.1.0 react-avatar-editor: specifier: ^13.0.2 version: 13.0.2(@babel/core@7.24.6)(react-dom@0.0.0-experimental-58af67a8f8-20240628(react@0.0.0-experimental-58af67a8f8-20240628))(react@0.0.0-experimental-58af67a8f8-20240628)