mirror of
https://github.com/lyx0/nourybot.git
synced 2024-11-13 19:49:55 +01:00
simplify command creation
This commit is contained in:
parent
6448c71fc1
commit
e5a1b3553f
|
@ -148,6 +148,15 @@ func (app *Application) handleCommand(message twitch.PrivateMessage) {
|
|||
return
|
||||
}
|
||||
|
||||
case "help":
|
||||
if msgLen < 2 {
|
||||
common.Send(target, "Not enough arguments provided. Usage: ()help <commandname>", app.TwitchClient)
|
||||
return
|
||||
} else {
|
||||
commands.Preview(target, cmdParams[1], app.TwitchClient)
|
||||
return
|
||||
}
|
||||
|
||||
// ()ping
|
||||
case "ping":
|
||||
commands.Ping(target, app.TwitchClient)
|
||||
|
|
Loading…
Reference in a new issue