[hot-fix] revert enter cmd

mine
derailed 2025-10-07 07:17:22 -06:00
parent 73fa008736
commit b53f3091ca
2 changed files with 2 additions and 6 deletions

View File

@ -190,9 +190,6 @@ func (a *App) ActivateCmd(b bool) {
// GetCmd retrieves user command. // GetCmd retrieves user command.
func (a *App) GetCmd() string { func (a *App) GetCmd() string {
if sugs := a.cmdBuff.Suggestions(); len(sugs) >= 1 {
return a.cmdBuff.GetText() + sugs[0]
}
return a.cmdBuff.GetText() return a.cmdBuff.GetText()
} }

View File

@ -626,9 +626,8 @@ func (a *App) toggleCrumbsCmd(evt *tcell.EventKey) *tcell.EventKey {
} }
func (a *App) gotoCmd(evt *tcell.EventKey) *tcell.EventKey { func (a *App) gotoCmd(evt *tcell.EventKey) *tcell.EventKey {
c := a.GetCmd() if a.CmdBuff().IsActive() && !a.CmdBuff().Empty() {
if a.CmdBuff().IsActive() && c != "" { a.gotoResource(a.GetCmd(), "", true, true)
a.gotoResource(c, "", true, true)
a.ResetCmd() a.ResetCmd()
return nil return nil
} }