File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change 88 ERR_UNKNOWN_SIGNAL
99 } ,
1010 uvErrmapGet,
11- overrideStackTrace,
1211} = require ( 'internal/errors' ) ;
1312const { signals } = internalBinding ( 'constants' ) . os ;
1413const {
@@ -340,12 +339,12 @@ function isInsideNodeModules() {
340339 // the perf implications should be okay.
341340 getStructuredStack = runInNewContext ( `(function() {
342341 Error.stackTraceLimit = Infinity;
342+ Error.prepareStackTrace = (err, trace) => trace;
343+
343344 return function structuredStack() {
344- const e = new Error();
345- overrideStackTrace.set(e, (err, trace) => trace);
346- return e.stack;
345+ return new Error().stack;
347346 };
348- })()` , { overrideStackTrace } , { filename : 'structured-stack' } ) ;
347+ })()` , { } , { filename : 'structured-stack' } ) ;
349348 }
350349
351350 const stack = getStructuredStack ( ) ;
You can’t perform that action at this time.
0 commit comments