Removed dead new_user_id() function
This commit is contained in:
parent
55a09b5e98
commit
383fd59eba
@ -1,14 +1,6 @@
|
||||
// This modules mainly deals with creating various types of random data
|
||||
use getrandom::getrandom;
|
||||
|
||||
pub fn new_user_id() -> u64 {
|
||||
let mut buf = [0u8; 8];
|
||||
match getrandom::getrandom(&mut buf) { // honestly if this fails idk wtf you want
|
||||
Ok(_val) => {u64::from_ne_bytes(buf)}
|
||||
Err(_e) => {0} // if this really happens we're fucked anyway
|
||||
}
|
||||
}
|
||||
|
||||
pub fn new_key() -> String {
|
||||
let mut raw_slice = [0u8; 64];
|
||||
let _ignored = getrandom(&mut raw_slice).unwrap();
|
||||
|
Loading…
Reference in New Issue
Block a user