Skip to content

Commit 6a97b65

Browse files
hknustwmfd00rman
authored andcommitted
Fixed issue with test timeout var definition in package.json and anonymous function def in util.js with arrow function.
1 parent 25e14b9 commit 6a97b65

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/util.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ function wrapRouteHandlers(route, app) {
114114
path = app.metrics.normalizeName(path || 'root');
115115
routerLayer.route.stack.forEach((layer) => {
116116
const origHandler = layer.handle;
117-
layer.handle = function (req, res, next) {
117+
layer.handle = (req, res, next) => {
118118
const startTime = Date.now();
119119
BBPromise.try(() => origHandler(req, res, next))
120120
.catch(next)

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"main": "./app.js",
66
"scripts": {
77
"start": "service-runner",
8-
"test": "PREQ_CONNECT_TIMEOUT=15 npm run lint && mocha",
8+
"test": "npm run lint && PREQ_CONNECT_TIMEOUT=15 mocha",
99
"lint": "eslint --max-warnings 0 --ext .js --ext .json .",
1010
"docker-start": "service-runner docker-start",
1111
"docker-test": "service-runner docker-test",

0 commit comments

Comments
 (0)