post login fixed
This commit is contained in:
parent
7c3132c54b
commit
1aa0c36c84
@ -71,7 +71,7 @@ router.post('/login', (request, response) => {
|
|||||||
const user = users.data.find(user => user.email === email && user.password === password);
|
const user = users.data.find(user => user.email === email && user.password === password);
|
||||||
|
|
||||||
if (!user) {
|
if (!user) {
|
||||||
response.status(401).send('Invalid credentials');
|
return response.status(401).send('Invalid credentials');
|
||||||
}
|
}
|
||||||
|
|
||||||
const responseObject = {
|
const responseObject = {
|
||||||
|
Loading…
Reference in New Issue
Block a user