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

Should not found be an error? #34

Closed
mmalecki opened this issue Nov 23, 2014 · 1 comment
Closed

Should not found be an error? #34

mmalecki opened this issue Nov 23, 2014 · 1 comment

Comments

@mmalecki
Copy link

Right now we if we can't find a document, we call back with an error. However, the error doesn't have too much information in it and user has to match against the message error to find out what happened.

Should we do that? In an ORM-ish/database access layer, not finding the document seems like a pretty normal occurrence, could we just return null as the document?

@Marak
Copy link
Member

Marak commented Nov 24, 2014

I see your point.

That will break a lot of things, but it's probably better to reserve errors for actual errors.

I would say yes to making this change in the upcoming version.

@Marak Marak closed this as completed Nov 24, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants