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

bug: fluent can't return 429 and other some other HTTP error codes #162

Open
ClemDoum opened this issue Oct 11, 2023 · 0 comments
Open

bug: fluent can't return 429 and other some other HTTP error codes #162

ClemDoum opened this issue Oct 11, 2023 · 0 comments

Comments

@ClemDoum
Copy link

Steps to reproduce:

WebServer().configure(routes -> routes.get("/", new Payload(429))).start(8080);

When curling http://localhost:8080, the status code will be 200.

This is because SimpleResponse.setStatus uses Status.getStatus(statusCode) from SimpleHttpFramework under the hood and the returns 200 when the statusCode is not in the Status enum.

429 is missing from this enum.

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