Skip to content

Commit

Permalink
Fix: Ignore bundled lib webpack on web
Browse files Browse the repository at this point in the history
  • Loading branch information
Nuckyz committed May 20, 2024
1 parent 5f8b96d commit 0a59512
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/webpack/patchWebpack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ Object.defineProperty(Function.prototype, "m", {
// When using react devtools or other extensions, we may also catch their webpack here.
// This ensures we actually got the right one
const { stack } = new Error();
if (stack?.includes("discord.com") || stack?.includes("discordapp.com")) {
if ((stack?.includes("discord.com") || stack?.includes("discordapp.com")) && !Array.isArray(v)) {
logger.info("Found Webpack module factory", stack.match(/\/assets\/(.+?\.js)/)?.[1] ?? "");
patchFactories(v);
}
Expand Down

0 comments on commit 0a59512

Please sign in to comment.