This repository has been archived by the owner on Aug 30, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2k
response code 500 on accessing non-existing document? #348
Comments
lirantal
added a commit
to lirantal/meanjs
that referenced
this issue
Jan 9, 2015
…article loading which isnt found we'll throw a 404 with json message
You're right @FREEZX so I committed a PR for that. |
@ilanbiala that's the route but it uses the :articleId parameter which is resolved using express's app.param() method. |
@lirantal yep, that's what I said. So what's the consensus, should we at least send a 400 if the id is not a valid ObjectId? I think we should start with that and work forward. |
lirantal
added a commit
that referenced
this issue
Jan 14, 2015
fixing issue #348 - instead of returning a server error 500 on article loading which isnt found we'll throw a 404 with json message
merged the relevant PR so I'm closing this. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hi,
I'm currently developing an application using mean, and something caught my attention:
https://github.com/meanjs/mean/blob/master/app/controllers/articles.server.controller.js#L93
This returns 500 internal server error if the document does not exist.
In my opinion this should send back 404 Not Found, without disclosing a stack trace.
The text was updated successfully, but these errors were encountered: