Changeset 334 in code for trunk/service.go
- Timestamp:
- Jun 10, 2020, 2:33:13 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/service.go
r333 r334 77 77 } 78 78 79 if cmd.handle == nil { 80 if len(cmd.children) > 0 { 81 var l []string 82 appendServiceCommandSetHelp(cmd.children, words, &l) 83 sendServicePRIVMSG(dc, "available commands: "+strings.Join(l, ", ")) 84 } else { 85 // Pretend the command does not exist if it has neither children nor handler. 86 // This is obviously a bug but it is better to not die anyway. 87 dc.logger.Printf("command without handler and subcommands invoked:", words[0]) 88 sendServicePRIVMSG(dc, fmt.Sprintf("command %q not found", words[0])) 89 } 90 return 91 } 92 79 93 if err := cmd.handle(dc, params); err != nil { 80 94 sendServicePRIVMSG(dc, fmt.Sprintf("error: %v", err))
Note:
See TracChangeset
for help on using the changeset viewer.