diff options
-rw-r--r-- | lib/ui/textinput.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ui/textinput.go b/lib/ui/textinput.go index f7301fb..f6b0c72 100644 --- a/lib/ui/textinput.go +++ b/lib/ui/textinput.go @@ -181,7 +181,7 @@ func (ti *TextInput) insert(ch rune) { func (ti *TextInput) deleteWord() { // TODO: Break on any of / " ' - if len(ti.text) == 0 { + if len(ti.text) == 0 || ti.index <= 0 { return } i := ti.index - 1 |