mirror of
https://github.com/youwen5/iamb.git
synced 2025-06-19 13:19:51 -07:00
Reset message bar when !
is passed with :cancel (#231)
This commit is contained in:
parent
6600685dd5
commit
79f6b5b75c
1 changed files with 5 additions and 3 deletions
|
@ -185,13 +185,15 @@ impl ChatState {
|
|||
|
||||
match act {
|
||||
MessageAction::Cancel(skip_confirm) => {
|
||||
self.reply_to = None;
|
||||
self.editing = None;
|
||||
|
||||
if skip_confirm {
|
||||
self.reset();
|
||||
|
||||
return Ok(None);
|
||||
}
|
||||
|
||||
self.reply_to = None;
|
||||
self.editing = None;
|
||||
|
||||
let msg = "Would you like to clear the message bar?";
|
||||
let act = PromptAction::Abort(false);
|
||||
let prompt = PromptYesNo::new(msg, vec![Action::from(act)]);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue