Skip to content

Commit

Permalink
Fix typos
Browse files Browse the repository at this point in the history
  • Loading branch information
jayvdb committed Feb 12, 2024
1 parent 5dec97c commit 008f841
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ Any error on the struct level validation will appear in the key `__all__` of the
Each validator can take 2 optional arguments in addition to their own arguments:

- `message`: a message to go with the error, for example if you want to do i18n
- `code`: each validator has a default error code (for example the `regex` validator code is `regex`) but it can be overriden
- `code`: each validator has a default error code (for example the `regex` validator code is `regex`) but it can be overridden
if necessary, mainly needed for the `custom` validator

Note that these arguments can't be applied to nested validation calls with `#[validate]`.
Expand Down
2 changes: 1 addition & 1 deletion validator_derive/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -587,7 +587,7 @@ fn find_validators_for_field(
let error_string = format!("{:?}", e);
if error_string == "Error(\"expected literal\")" {
abort!(attr.span(),
"This attributes for the field `{}` seem to be misformed, please validate the syntax with the documentation",
"This attributes for the field `{}` seem to be malformed, please validate the syntax with the documentation",
field_ident
);
} else {
Expand Down

0 comments on commit 008f841

Please sign in to comment.