Skip to content

Commit

Permalink
set message on password validator (#128)
Browse files Browse the repository at this point in the history
* set message on password validator

fix for #123

* Update user.rs
  • Loading branch information
JensTimmerman authored Sep 27, 2021
1 parent 9a5553a commit 5d38546
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/models/user.rs
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ lazy_static! {
pub struct NewUser {
#[validate(regex = "NEW_USER_REGEX")]
pub username: String,
#[validate(length(min = 8))]
#[validate(length(min = 8, message = "Password to short"))]
pub password: String,
#[validate(length(min = 3, max = 254))]
pub full_name: String,
Expand Down

0 comments on commit 5d38546

Please sign in to comment.