Skip to content

Commit f6d1184

Browse files
filipesilvahansl
authored andcommitted
build: only set infinite stack trace with --long-stack-trace
1 parent 3a3155b commit f6d1184

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/bootstrap-local.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,9 @@ if (process.env['DEVKIT_PROFILING']) {
4545
process.on('uncaughtException', exitHandler.bind(null, { exit: true }));
4646
}
4747

48-
49-
Error.stackTraceLimit = Infinity;
48+
if (process.argv.indexOf('--long-stack-trace') !== -1){
49+
Error.stackTraceLimit = Infinity;
50+
}
5051

5152
global._DevKitIsLocal = true;
5253
global._DevKitRoot = path.resolve(__dirname, '..');

0 commit comments

Comments
 (0)