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

Rejected promises show up as errors but keep a 200 status code #51

Open
sazzer opened this issue May 20, 2017 · 0 comments
Open

Rejected promises show up as errors but keep a 200 status code #51

sazzer opened this issue May 20, 2017 · 0 comments

Comments

@sazzer
Copy link

sazzer commented May 20, 2017

If I use the following configuration:

    app.use(healthCheck({
        stats: {
            demo: () => Promise.reject(new Error('Its broke'))
        }
    }));

Then I get the following in the output:

  "errors": [
    "Its broke"
  ]

But I still get a Status Code of 200, instead of a 500 like I'd expect.

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

1 participant