-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Missing language
entry in joi.extend
causes obscure runtime error
#1230
Comments
It can't be done at extension time as it would mean parsing your code, but it can certainly be improved at validation time. |
Can you not check that a property in |
No, new rules might re-use existing errors or throw several kinds, that's impossible. |
Ah ok, makes sense 🙂 |
Closed by mistake, sorry. |
ty |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Context
What are you trying to achieve or the steps to reproduce ?
Which result you had ?
Upon using the rule via
.validate
an error gets thrown.What did you expect ?
I would expect to get an error upon calling
extend
telling me that the language entry is required.The text was updated successfully, but these errors were encountered: