feat(frontend): scaffolding to build frontend

- Added `make fnginx` to have better dev experience
- Added app.conf to nginx configuration to handle frontend
This commit is contained in:
Maieul BOYER 2025-11-10 16:58:42 +01:00 committed by Maix0
parent 5dd6067c95
commit 0db41a440d
11 changed files with 186 additions and 10 deletions

View file

@ -33,10 +33,10 @@ const route: FastifyPluginAsync = async (fastify, _opts): Promise<void> => {
// does the user exist
// does it have a password setup ?
if (isNullish(user?.password)) { return res.makeResponse(403, 'failed', 'login.failed.invalid'); }
if (isNullish(user?.password)) { return res.makeResponse(400, 'failed', 'login.failed.invalid'); }
// does the password he provided match the one we have
if (!(await verifyUserPassword(user, password))) { return res.makeResponse(403, 'failed', 'login.failed.invalid'); }
if (!(await verifyUserPassword(user, password))) { return res.makeResponse(400, 'failed', 'login.failed.invalid'); }
// does the user has 2FA up ?
if (!isNullish(user.otp)) {