Skip to content

Commit 70137ee

Browse files
committed
Remove redundant check
1 parent 898991b commit 70137ee

File tree

1 file changed

+16
-18
lines changed

1 file changed

+16
-18
lines changed

packages/cli-menu/src/menu.ts

Lines changed: 16 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -91,24 +91,22 @@ export function menu({
9191
if (!isEnabled) return;
9292
}
9393

94-
if (!commandString.length) {
95-
const selectedCommands = await commandPrompt({
96-
title,
97-
titleColors,
98-
message,
99-
showDescriptions,
100-
maxDescriptionLength,
101-
client: context.client,
102-
commandsDir,
103-
resolveFn: ({ commandString, commandsDir }) =>
104-
context.resolveCommand(commandString, commandsDir),
105-
onCancel: async () => {
106-
await context.exit();
107-
},
108-
});
109-
addResolvedCommands(selectedCommands);
110-
skip();
111-
}
94+
const selectedCommands = await commandPrompt({
95+
title,
96+
titleColors,
97+
message,
98+
showDescriptions,
99+
maxDescriptionLength,
100+
client: context.client,
101+
commandsDir,
102+
resolveFn: ({ commandString, commandsDir }) =>
103+
context.resolveCommand(commandString, commandsDir),
104+
onCancel: async () => {
105+
await context.exit();
106+
},
107+
});
108+
addResolvedCommands(selectedCommands);
109+
skip();
112110
},
113111
);
114112

0 commit comments

Comments
 (0)