Skip to content

Commit 4fe1bc6

Browse files
committed
1 parent d6fd675 commit 4fe1bc6

File tree

1 file changed

+1
-15
lines changed

1 file changed

+1
-15
lines changed

lib/index.js

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6,22 +6,8 @@
66
const util = require('util');
77
const axios = require('axios');
88

9-
function wrapErrorsWithInspect(items) {
10-
return items.map((item) => {
11-
if ((item instanceof Error) && item.stack) {
12-
return {
13-
inspect: function () {
14-
return `${util.format(item)}\n${item.stack}`;
15-
}
16-
};
17-
}
18-
19-
return item;
20-
});
21-
}
22-
239
function format(logData) {
24-
return util.format.apply(util, wrapErrorsWithInspect(logData));
10+
return util.format(...logData);
2511
}
2612

2713
/**

0 commit comments

Comments
 (0)