fix panic for empty shell completions
This commit is contained in:
parent
751290ed9b
commit
22b157a8fa
2
comp.go
2
comp.go
@ -237,7 +237,7 @@ func compCmd(acc []rune) (matches []string, longestAcc []rune) {
|
|||||||
|
|
||||||
func compShell(acc []rune) (matches []string, longestAcc []rune) {
|
func compShell(acc []rune) (matches []string, longestAcc []rune) {
|
||||||
s := string(acc)
|
s := string(acc)
|
||||||
f := strings.Fields(s)
|
f := tokenize(s)
|
||||||
|
|
||||||
var longest string
|
var longest string
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user