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

Mark NesErrors as coming from nes #228

Merged
merged 4 commits into from Mar 15, 2018

Conversation

@dominykas
Copy link
Contributor

dominykas commented Mar 14, 2018

  • Added isNes property so the consumers can handle nes errors differently if they chose to
  • Add constants for NesError types (mostly to make the usages more searchable and visible in one place)
  • Added a [re]throw inside NesError to ensure stack on IE11
dominykas added 4 commits Mar 14, 2018
This makes it easier to reason about errors coming from nes - the use case is to try to customize an error message shown to the end user based on error type for passing on to support/helpdesk.
IE does not initialize the `stack` property until the error is thrown.
@mtharrison mtharrison added the feature label Mar 15, 2018
@mtharrison mtharrison merged commit ea8f295 into hapijs:master Mar 15, 2018
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@mtharrison mtharrison added this to the 7.2.0 milestone Mar 15, 2018
@mtharrison mtharrison self-assigned this Mar 15, 2018
@dominykas dominykas deleted the dominykas:nes-error-is-nes branch Mar 15, 2018
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.