Find all missing logic in a Node.js Express /authenticate endpoint.
Unlock detailed company stats for this questionUpgrade
An Express /authenticate endpoint takes a username and password, runs a DB query, and uses a bcrypt password hash match to return a 200 or an error. Identify all missing logic (e.g., input validation, proper error handling, appropriate HTTP status codes). The bcrypt compare is synchronous and must be made asynchronous so it does not block the event loop.
Format · Live debugging/optimization exercise.
Community answers
No answers contributed by the community yet.
Related courses

Course

Course
Course
