summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--packages/tui/internal/commands/command.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/packages/tui/internal/commands/command.go b/packages/tui/internal/commands/command.go
index ae34f4b52..d552b78ec 100644
--- a/packages/tui/internal/commands/command.go
+++ b/packages/tui/internal/commands/command.go
@@ -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))
})