mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2025-04-07 18:44:29 -04:00
Fix error 500 when resetting password if bad input.
This commit is contained in:
parent
3b16145d39
commit
8895f12aff
1 changed files with 1 additions and 1 deletions
|
@ -56,7 +56,7 @@ module.exports.setupRoutes = (app) ->
|
|||
|
||||
app.post('/auth/reset', (req, res) ->
|
||||
unless req.body.email
|
||||
return errors.badInput(res, [{message:'Need an email specified.', property:email}])
|
||||
return errors.badInput(res, [{message:'Need an email specified.', property:'email'}])
|
||||
|
||||
User.findOne({emailLower:req.body.email.toLowerCase()}).exec((err, user) ->
|
||||
if not user
|
||||
|
|
Loading…
Add table
Reference in a new issue