fix(tui): sort custom commands lower
parent
6357136ca5
commit
836c2060c7
|
|
@ -92,12 +92,12 @@ func (r CommandRegistry) Sorted() []Command {
|
|||
if b.Name == AppExitCommand {
|
||||
return -1
|
||||
}
|
||||
if a.Custom {
|
||||
return -1
|
||||
}
|
||||
if b.Custom {
|
||||
if a.Custom && !b.Custom {
|
||||
return 1
|
||||
}
|
||||
if !a.Custom && b.Custom {
|
||||
return -1
|
||||
}
|
||||
|
||||
return strings.Compare(string(a.Name), string(b.Name))
|
||||
})
|
||||
|
|
|
|||
Loading…
Reference in New Issue