We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
It looks like field is validated anyway, even it's wrapped with the Option, is it default behaviour or a bug? for example:
#[derive(Default, Debug, Clone, PartialEq, Serialize, Deserialize, Validate)] pub struct Port { #[validate(pattern = r"^\d{2,6}+$")] pub host_port: Option<String>,
I expected this field not to be validated when empty or should I use rules for that case ?
The text was updated successfully, but these errors were encountered:
Sorry my bad, not an issue, because I get Some("") not None
Sorry, something went wrong.
No branches or pull requests
It looks like field is validated anyway, even it's wrapped with the Option, is it default behaviour or a bug?
for example:
I expected this field not to be validated when empty or should I use rules for that case ?
The text was updated successfully, but these errors were encountered: