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

null values in json are not handled correctly #52

Open
zUnixorn opened this issue Oct 4, 2023 · 0 comments
Open

null values in json are not handled correctly #52

zUnixorn opened this issue Oct 4, 2023 · 0 comments
Assignees
Labels
bug Something isn't working Core

Comments

@zUnixorn
Copy link
Member

zUnixorn commented Oct 4, 2023

when sending a json with either valid_for or max_uses set to null, the return code is 400 Bad Request and a serde error message is returned in the response. The 400 may be wanted although null fields could just be treated as not existing, but the error message should not be a serde parsing error

reproduce with:
http POST https://s.flamion.dev/custom link=do_not_care max_uses=null valid_for=null
or
curl --request POST --header "Content-Type: application/json" --data '{"link":"do_not_care","valid_for":null,"max_uses":null}' https://s.flamion.dev/custom

@zUnixorn zUnixorn added bug Something isn't working Core labels Oct 4, 2023
@flamion flamion self-assigned this Oct 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Core
Projects
None yet
Development

No branches or pull requests

2 participants