mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 18:55:26 +00:00
fix(console) addListeners disconnect: check prompt state before abort
This commit is contained in:
parent
8a4787c875
commit
68d6ce0578
1 changed files with 5 additions and 1 deletions
|
|
@ -174,8 +174,12 @@ var CloudCmd, Util, DOM, CloudFunc, $;
|
|||
},
|
||||
|
||||
'disconnect': function() {
|
||||
var state = jqconsole.GetState();
|
||||
|
||||
error(Socket.DISCONNECTED);
|
||||
jqconsole.AbortPrompt();
|
||||
|
||||
if (state === 'prompt')
|
||||
jqconsole.AbortPrompt();
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue