From c2ce5295eb27610734ed539d47979c7bc0f0953b Mon Sep 17 00:00:00 2001 From: boastful-squirrel Date: Sat, 27 Apr 2019 12:31:14 +0200 Subject: Fixed test + fixed clippy warning --- src/auth.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/auth.rs') diff --git a/src/auth.rs b/src/auth.rs index d8de30e..a42bb53 100644 --- a/src/auth.rs +++ b/src/auth.rs @@ -75,8 +75,8 @@ pub fn match_auth(basic_auth: BasicAuthParams, required_auth: &RequiredAuth) -> } /// Return `true` if hashing of `password` by `T` algorithm equals to `hash` -pub fn compare_hash(password: String, hash: &Vec) -> bool { - get_hash::(password) == *hash +pub fn compare_hash(password: String, hash: &[u8]) -> bool { + get_hash::(password) == hash } /// Get hash of a `text` -- cgit v1.2.3