Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add timestamping logins #5

Open
alielbashir opened this issue Mar 18, 2022 · 0 comments
Open

Add timestamping logins #5

alielbashir opened this issue Mar 18, 2022 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@alielbashir
Copy link
Owner

alielbashir commented Mar 18, 2022

Timestamping all successful login attempts should be done within the /login route's controller.

router.post("/login", async (req, res) => {
const username = req.body.username;
const password = req.body.password;
try {
console.log(`awaiting db...`)
const data = await databaseClient.query(
`SELECT * FROM users WHERE username = $1 AND password = $2`,
[username, password]

@alielbashir alielbashir added the enhancement New feature or request label Mar 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants