Skip to content

Commit

Permalink
fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
jackkav committed Jul 1, 2024
1 parent 2653b4c commit 4373ea8
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 12 deletions.
19 changes: 11 additions & 8 deletions lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,17 @@ module.exports = function (options) {

endpoints.forEach((endpoint) => {
// assign router to action at path
router[endpoint.action].apply(router, [endpoint.path].concat([
mw.errorHandler,
mw.bodyParser,
endpoint.route,
mw.cors,
mw.poweredBy,
mw.negotiateContent,
]));
router[endpoint.action].apply(
router,
[endpoint.path].concat([
mw.errorHandler,
mw.bodyParser,
endpoint.route,
mw.cors,
mw.poweredBy,
mw.negotiateContent,
]),
);
});

if (options?.redis) {
Expand Down
9 changes: 5 additions & 4 deletions lib/routes/bins.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,15 +62,16 @@ module.exports = function bins(dsnStr) {

endpoints.forEach((endpoint) => {
// assign router to action at path
router[endpoint.action].apply(router, [endpoint.path].concat(
[
router[endpoint.action].apply(
router,
[endpoint.path].concat([
mw.errorHandler,
mw.bodyParser,
endpoint.route,
mw.cors,
mw.negotiateContent,
]
));
]),
);
});

return router;
Expand Down

0 comments on commit 4373ea8

Please sign in to comment.