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

Don't catch synchronous handler errors #9

Merged
merged 1 commit into from Jul 1, 2015

Conversation

@connor4312
Copy link
Contributor

connor4312 commented Jun 13, 2015

Previously, synchronous errors in the call stack of next() (including the route handler, in Hapi servers), were eaten by the try/catch and thrown as "invalid JSON payloads", even though they likely should have been treated as internal server errors.

I had difficulty writing a specific test case for this, but the fix does work in our application and does not break any other tests.

@hueniverse hueniverse added the bug label Jul 1, 2015
@hueniverse hueniverse added this to the 1.1.0 milestone Jul 1, 2015
@hueniverse hueniverse self-assigned this Jul 1, 2015
hueniverse added a commit that referenced this pull request Jul 1, 2015
Don't catch synchronous handler errors
@hueniverse hueniverse merged commit badd844 into hapijs:master Jul 1, 2015
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
hueniverse added a commit that referenced this pull request Jul 1, 2015
@hueniverse

This comment has been minimized.

Copy link
Member

hueniverse commented Jul 1, 2015

See test for how to verify the change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.