Skip to content

Commit a88d03e

Browse files
committed
refactor(init): use rng instead of deprecated thread_rng
1 parent 642a7bd commit a88d03e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

rustmail/src/bot.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ pub async fn init_bot_state() -> Arc<Mutex<BotState>> {
2828
println!("Database connected!");
2929

3030
let mut bytes = [0u8; 32];
31-
rand::thread_rng().fill_bytes(&mut bytes);
31+
rand::rng().fill_bytes(&mut bytes);
3232
let token = base64::engine::general_purpose::STANDARD.encode(&bytes);
3333

3434
let config = load_config("config.toml");

0 commit comments

Comments
 (0)