Skip to content

Commit d57e477

Browse files
committed
fix: boolean oopsie
1 parent 8f6bd91 commit d57e477

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/nitro/src/sourceMaps.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ export function getPluginOptions(options?: SentryNitroOptions): Options {
9696
*/
9797
export function configureSourcemapSettings(config: NitroConfig, moduleOptions?: SentryNitroOptions): void {
9898
const sourcemapUploadDisabled = moduleOptions?.sourcemaps?.disable === true || moduleOptions?.disable === true;
99-
if (!sourcemapUploadDisabled) {
99+
if (sourcemapUploadDisabled) {
100100
return;
101101
}
102102

@@ -105,11 +105,13 @@ export function configureSourcemapSettings(config: NitroConfig, moduleOptions?:
105105
'[Sentry] You have explicitly disabled source maps (`sourcemap: false`). Sentry is overriding this to `true` so that errors can be un-minified in Sentry. To disable Sentry source map uploads entirely, use `sourcemaps: { disable: true }` in your Sentry options instead.',
106106
);
107107
}
108+
108109
config.sourcemap = true;
109110

110111
// Nitro v3 has a `sourcemapMinify` plugin that destructively deletes `sourcesContent`,
111112
// `x_google_ignoreList`, and clears `mappings` for any chunk containing `node_modules`.
112113
// This makes sourcemaps unusable for Sentry.
114+
// FIXME: Not sure about this one, it works either way?
113115
config.experimental = config.experimental || {};
114116
config.experimental.sourcemapMinify = false;
115117

0 commit comments

Comments
 (0)