You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Correct me if I'm wrong, but currently all validators will be executed even if some of them fails during the validation process. I believe this is the corresponding code chunk, showing the nature of this behavior:
I believe that it should be possible to instruct Grape to fail fast during the validation process.
One possible case: We need to validate that some string matches some pattern (for example it is an email) and than we need to validate if this email is in the white list. For now even if this email is malformed, it will be checked against the white list (which has no sense cause it is malformed anyway).
Correct me if I'm wrong, but currently all validators will be executed even if some of them fails during the validation process. I believe this is the corresponding code chunk, showing the nature of this behavior:
I believe that it should be possible to instruct Grape to fail fast during the validation process.
One possible case: We need to validate that some string matches some pattern (for example it is an email) and than we need to validate if this email is in the white list. For now even if this email is malformed, it will be checked against the white list (which has no sense cause it is malformed anyway).
The DSL may look like this:
The text was updated successfully, but these errors were encountered: