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

Empty path in "suggestions" after validate request-body #6

Open
littlefuntik opened this issue Oct 13, 2018 · 3 comments
Open

Empty path in "suggestions" after validate request-body #6

littlefuntik opened this issue Oct 13, 2018 · 3 comments

Comments

@littlefuntik
Copy link

littlefuntik commented Oct 13, 2018

After validate request-body I get error, but path property is empty. Why?
See debug screnshot (see valid screenshot bottom)

@littlefuntik
Copy link
Author

I found answer. Maby, you are missing ajv validation error field: "params".
See problem here: ajv-validator/ajv#93 (comment)

@supertong
Copy link
Collaborator

Thanks for reporting @littlefuntik , I can't see the screenshot for some reason. Would you be able to provide the examples by code?
As far as I know the path will be empty if the error is on the root level, and that's the behaviour of better-ajv-errors which is used to parse the error message.

@littlefuntik
Copy link
Author

I can't see the screenshot for some reason.

Debug screen (Imgur)

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

2 participants