Files
nginx-proxy-manager/backend/lib/express/jwt-decode.js
Jamie Curnow 0b2fa826e0 Introducing the Setup Wizard for creating the first user
- no longer setup a default
- still able to do that with env vars however
2025-10-02 08:12:05 +10:00

16 lines
295 B
JavaScript

import Access from "../access.js";
export default () => {
return async (_, res, next) => {
try {
res.locals.access = null;
const access = new Access(res.locals.token || null);
await access.load();
res.locals.access = access;
next();
} catch (err) {
next(err);
}
};
};