handleDefault treats "/ [args]" as a manual skill invocation when resolves to an installed user-invocable skill; otherwise it reports an unknown command.
(ctx context.Context, userInput string)
| 154 | // <name> resolves to an installed user-invocable skill; otherwise it reports |
| 155 | // an unknown command. |
| 156 | func (ch *CommandHandler) handleDefault(ctx context.Context, userInput string) bool { |
| 157 | if ch.tryInvokeUserSkill(ctx, userInput) { |
| 158 | return false |
| 159 | } |
| 160 | fmt.Println(i18n.T("error.unknown_command")) |
| 161 | return false |
| 162 | } |
| 163 | |
| 164 | // buildRoutes wires every command to its handler. Keeping this as data (not |
| 165 | // control flow) is what holds HandleCommand's complexity down. |
no test coverage detected