Reduce a little bit bcrypt cost

From 12 to 10, to make login time shorter.
This commit is contained in:
Bat 2018-09-03 17:51:32 +01:00
parent ac631627ab
commit 78b3202a32

View File

@ -228,7 +228,7 @@ impl User {
} }
pub fn hash_pass(pass: String) -> String { pub fn hash_pass(pass: String) -> String {
bcrypt::hash(pass.as_str(), bcrypt::DEFAULT_COST).unwrap() bcrypt::hash(pass.as_str(), 10).unwrap()
} }
pub fn auth(&self, pass: String) -> bool { pub fn auth(&self, pass: String) -> bool {