1
0
Fork 0
mirror of https://github.com/dani-garcia/vaultwarden.git synced 2025-09-06 09:42:41 +00:00

Updated deps and fixed some lints

This commit is contained in:
Daniel García 2019-11-28 21:59:05 +01:00
commit 1e224220a8
No known key found for this signature in database
GPG key ID: FC8A7D14C3CD543A
3 changed files with 121 additions and 97 deletions

View file

@ -500,13 +500,13 @@ impl Config {
}
pub fn can_signup_user(&self, email: &str) -> bool {
let e: Vec<&str> = email.rsplitn(2, "@").collect();
let e: Vec<&str> = email.rsplitn(2, '@').collect();
if e.len() != 2 || e[0].is_empty() || e[1].is_empty() {
warn!("Failed to parse email address '{}'", email);
return false
}
self.signups_domains_whitelist().split(",").any(|d| d == e[0])
self.signups_domains_whitelist().split(',').any(|d| d == e[0])
}
pub fn delete_user_config(&self) -> Result<(), Error> {