|
|
@ -19,7 +19,7 @@ use crate::try_log;
|
|
|
|
/// use rude::hash::*;
|
|
|
|
/// use rude::hash::*;
|
|
|
|
/// let data = "butterflies";
|
|
|
|
/// let data = "butterflies";
|
|
|
|
/// let salt = salt();
|
|
|
|
/// let salt = salt();
|
|
|
|
/// println!("{}", hash(data, salt));
|
|
|
|
/// println!("{}", hash(data, salt).unwrap());
|
|
|
|
/// ```
|
|
|
|
/// ```
|
|
|
|
pub fn hash<D: Into<String>, S: Into<String>>(data: D, salt: S) -> RudeResult<String> {
|
|
|
|
pub fn hash<D: Into<String>, S: Into<String>>(data: D, salt: S) -> RudeResult<String> {
|
|
|
|
Ok(try_log!(
|
|
|
|
Ok(try_log!(
|
|
|
|