Skip to content

Commit da82c65

Browse files
committed
disable plugin in non-prod vercel environments
1 parent d7ae99f commit da82c65

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

packages/nextjs/src/config/webpack.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -487,6 +487,10 @@ function shouldEnableWebpackPlugin(buildContext: BuildContext, userSentryOptions
487487
// return false
488488
}
489489

490+
if (process.env.VERCEL_ENV === 'preview' || process.env.VERCEL_ENV === 'development') {
491+
return false;
492+
}
493+
490494
// We've passed all of the tests!
491495
return true;
492496
}

0 commit comments

Comments
 (0)