mirror of
https://github.com/qwertyforce/scenery.git
synced 2025-05-31 03:32:30 +00:00
login/signup 403
This commit is contained in:
parent
db5127083a
commit
f83e2553fd
@ -23,7 +23,7 @@ async function login(req:Request,res:Response) {
|
||||
const users = await db_ops.activated_user.find_user_by_email(email);
|
||||
if (users.length === 0) {
|
||||
await crypto_ops.check_password("Random_text_qwfqwfg", "$2b$10$xKgSc736RxzT76ZMGyXMLe1Dge99d4PLyUOv60jpywAWJwftYcgjK"); // PROTECTION AGAINST TIMING ATTACK
|
||||
res.json({
|
||||
res.status(403).json({
|
||||
message: MESSAGE_FOR_AUTH_ERROR
|
||||
})
|
||||
} else {
|
||||
|
@ -31,7 +31,7 @@ async function signup(req:Request,res:Response) {
|
||||
})
|
||||
} else {
|
||||
console.log(users)
|
||||
res.json({
|
||||
res.status(403).json({
|
||||
message: 'User with same email is already registered'
|
||||
})
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user