Skip to content

Commit 876f512

Browse files
committed
print the reason in unhandledRejection evnet if reason.stack does not exist
1 parent 14ffafd commit 876f512

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

api.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ function registerEvents() {
147147
});
148148

149149
process.on('unhandledRejection', function(reason) {
150-
log.error(reason.stack);
150+
log.error(reason.stack || reason);
151151
process.exit(1);
152152
});
153153
}

0 commit comments

Comments
 (0)