Skip to content

Commit 897678e

Browse files
committed
refactor: server: auth: destructure
1 parent dff0267 commit 897678e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

server/auth.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,9 @@ module.exports = (config) => {
1616

1717
function _middle(config, authentication, req, res, next) {
1818
const is = config('auth');
19+
const {originalUrl} = req;
1920

20-
if (!is || req.originalUrl.startsWith("/public/"))
21+
if (!is || originalUrl.startsWith("/public/"))
2122
return next();
2223

2324
const success = () => next();

0 commit comments

Comments
 (0)