diff --git a/src/js/commandline.js b/src/js/commandline.js index 065286a9e..b921f8502 100644 --- a/src/js/commandline.js +++ b/src/js/commandline.js @@ -527,13 +527,20 @@ $(document).keydown((e) => { return; } } - if ( - e.key === "Backspace" && - $("#commandLine input").val()[0] == ">" && - Config.singleListCommandLine == "manual" && - isSingleListCommandLineActive() - ) - restoreOldCommandLine(false); + + if (e.key === "Backspace") { + setTimeout(() => { + let inputVal = $("#commandLine input").val(); + if ( + Config.singleListCommandLine == "manual" && + isSingleListCommandLineActive() && + inputVal[0] !== ">" + ) { + restoreOldCommandLine(); + } + }, 1); + } + if (e.key === "Enter") { //enter e.preventDefault();