mirror of
https://github.com/lyx0/nourybot.git
synced 2024-11-13 19:49:55 +01:00
make echo return more than one word
This commit is contained in:
parent
3efcfd31cc
commit
4034999fac
3 changed files with 9 additions and 1 deletions
7
pkg/commands/echo.go
Normal file
7
pkg/commands/echo.go
Normal file
|
@ -0,0 +1,7 @@
|
|||
package commands
|
||||
|
||||
import "github.com/gempir/go-twitch-irc/v2"
|
||||
|
||||
func Echo(channel string, message string, client *twitch.Client) {
|
||||
client.Say(channel, message)
|
||||
}
|
1
pkg/commands/xd.go
Normal file
1
pkg/commands/xd.go
Normal file
|
@ -0,0 +1 @@
|
|||
package commands
|
|
@ -44,7 +44,7 @@ func HandleCommand(message twitch.PrivateMessage, twitchClient *twitch.Client, u
|
|||
twitchClient.Say(message.Channel, "xd")
|
||||
return
|
||||
case "echo":
|
||||
twitchClient.Say(message.Channel, cmdParams[1])
|
||||
commands.Echo(message.Channel, message.Message[7:len(message.Message)], twitchClient)
|
||||
return
|
||||
case "ping":
|
||||
commands.Ping(message.Channel, twitchClient, uptime)
|
||||
|
|
Loading…
Reference in a new issue