Skip to content

Commit

Permalink
Don't warn when source-map-support is not present
Browse files Browse the repository at this point in the history
  • Loading branch information
myndzi committed Jul 14, 2021
1 parent 453c5a5 commit c324706
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,10 @@ function setupAsyncHooks() {
var _Error_prepareStackTrace = Error.prepareStackTrace;
try {
sms = require('source-map-support');
} catch (e) {
return;
}
try {
Error.prepareStackTrace = getMappedStackFrames;
(new Error('synthetic')).stack;
Error.prepareStackTrace = _Error_prepareStackTrace;
Expand Down

0 comments on commit c324706

Please sign in to comment.