Added GetNewMasterPass state and added restrictions on the master password
This commit is contained in:
@ -1,6 +1,6 @@
|
||||
use crate::markups::deletion_markup;
|
||||
use arrayvec::ArrayString;
|
||||
use cryptography::password_generation::generate_passwords;
|
||||
use cryptography::passwords::generate_passwords;
|
||||
use std::fmt::Write;
|
||||
use teloxide::{adaptors::Throttle, prelude::*, types::ParseMode};
|
||||
use tokio::task::spawn_blocking;
|
||||
|
@ -44,7 +44,10 @@ pub async fn set_master_pass(
|
||||
.send_message(msg.chat.id, "Send new master password")
|
||||
.await?;
|
||||
dialogue
|
||||
.update(State::GetPassword(Handler::new(get_master_pass, previous)))
|
||||
.update(State::GetNewMasterPass(Handler::new(
|
||||
get_master_pass,
|
||||
previous,
|
||||
)))
|
||||
.await?;
|
||||
Ok(())
|
||||
}
|
||||
|
Reference in New Issue
Block a user