1 | "use strict";
|
2 |
|
3 |
|
4 |
|
5 |
|
6 | Object.defineProperty(exports, "__esModule", { value: true });
|
7 |
|
8 |
|
9 |
|
10 |
|
11 |
|
12 | function createUnexpectedHttpErrorLogger(expectedStatusCode) {
|
13 | return function logUnexpectedHttpError(err, statusCode, req) {
|
14 | if (statusCode === expectedStatusCode)
|
15 | return;
|
16 |
|
17 | console.error('Unhandled error in %s %s: %s %s', req.method, req.url, statusCode, err.stack || err);
|
18 | };
|
19 | }
|
20 | exports.createUnexpectedHttpErrorLogger = createUnexpectedHttpErrorLogger;
|
21 |
|
\ | No newline at end of file |