passport auth integrated to login route

This commit is contained in:
Mikayla Dobson
2022-07-05 19:34:39 -05:00
parent 4b4c7a7bb0
commit 8029bf34f4
3 changed files with 10 additions and 10 deletions

View File

@@ -30,10 +30,7 @@ async function LoginService(email, password) {
userProfile: fullUserProfile.rows[0]
}
} else {
return {
session: 'not found',
userProfile: 'not found'
}
throw new Error("Auth unsuccessful.");
}
} catch(e) {
await client.query("ROLLBACK");