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

Return from Custom validators (added through CustomTypeTagMap) error instead of bool #444

Open
sergeyglazyrindev opened this issue Jun 9, 2021 · 0 comments · May be fixed by #450
Open

Comments

@sergeyglazyrindev
Copy link

Feature Request

New Feature : yes
RFC: no
BC Break: no

Summary

Hello guys!
I am writing some go project and I thought it would be better if we return from custom validators specific error, instead of boolean. That helps to use custom validators to validate different possible wrong cases. Basically, in my project I wanted to create custom validator to validate username against few rules, instead of writing long struct field annotations.
But seems like it's not possible right now.
I can do that if community likes this idea.

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

Successfully merging a pull request may close this issue.

1 participant