File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
src/hooks/command_not_found Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -14,13 +14,13 @@ const hook: Hook.CommandNotFound = async function (opts) {
14
14
help . showHelp ( [ '--help' ] ) ;
15
15
return ;
16
16
}
17
- const hiddenCommandIds = new Set ( opts . config . commands . filter ( ( c ) => { c . hidden ; } ) . map ( ( c ) => c . id ) ) ;
17
+ const hiddenCommandIds = new Set ( opts . config . commands . filter ( ( c ) => c . hidden ) . map ( ( c ) => c . id ) ) ;
18
18
const commandIDs = [ ...opts . config . commandIDs , ...opts . config . commands . flatMap ( ( c ) => c . aliases ) ] . filter (
19
19
( c ) => ! hiddenCommandIds . has ( c ) ,
20
20
) ;
21
- //here we get the command ids and hidden command ids.
22
21
23
22
if ( commandIDs . length === 0 ) { return ; }
23
+
24
24
// now we we return if the command id are not there.
25
25
26
26
let binHelp = `${ opts . config . bin } help` ;
You can’t perform that action at this time.
0 commit comments