ensure generated hash is safe
This commit is contained in:
parent
d488f1a887
commit
890b4e05d2
1 changed files with 5 additions and 5 deletions
|
|
@ -2,7 +2,7 @@ use base64::Engine;
|
|||
|
||||
use crate::config::SabryHashConfig;
|
||||
|
||||
use super::ArbitraryScope;
|
||||
use super::{apply_basic_rusty_member_gen_rules, ArbitraryScope};
|
||||
|
||||
/// Convenience wrapper for String-being-a-hash
|
||||
#[derive(Debug, Clone, PartialEq, Eq, Hash)]
|
||||
|
|
@ -50,6 +50,7 @@ impl ScopeHash {
|
|||
//? This isn't right. "size" is size of hash in symbols.
|
||||
// naaah, its fine :D (Dan)
|
||||
let hash = base64::prelude::BASE64_URL_SAFE_NO_PAD.encode(&hash[..size]);
|
||||
let hash = apply_basic_rusty_member_gen_rules(&hash);
|
||||
|
||||
Self(hash)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue