forked from kageru/discord-selphybot
remove debug stuff. refactor done \o/
This commit is contained in:
parent
5a1b51195b
commit
1e20ff9b45
|
@ -69,7 +69,6 @@ func evaluateMessage(s *discordgo.Session, m *discordgo.MessageCreate) {
|
|||
log.Printf("<Self> %s", m.Content)
|
||||
return
|
||||
}
|
||||
fmt.Println(m.Content)
|
||||
for i, command := range commands {
|
||||
content := m.Content
|
||||
if command.IgnoreCase {
|
||||
|
@ -114,7 +113,6 @@ func executeCommand(session *discordgo.Session, message *discordgo.MessageCreate
|
|||
(!command.DMOnly || (getChannel(session.State, message.ChannelID).Type == discordgo.ChannelTypeDM))) {
|
||||
|
||||
log.Printf("Executed command %s triggered by user %s", command.Trigger, userToString(message.Author))
|
||||
fmt.Printf("Executed command %s triggered by user %s", command.Trigger, userToString(message.Author))
|
||||
if command.Cooldown > 0 {
|
||||
commands[commandIndex].IsOnCooldown = true
|
||||
go removeCooldown(commandIndex)
|
||||
|
|
2
main.go
2
main.go
|
@ -69,7 +69,7 @@ func addCommands() {
|
|||
registerCommand(Command{Trigger: "<@%s> <3", Output: "<@%s> <3", Type: CommandTypeFullMatch, AdminOnly: true, OutputIsReply: true, RequiresMention: true})
|
||||
|
||||
// Debug
|
||||
registerCommand(Command{Trigger: "echo", Type: CommandTypePrefix, Function: echoMessage})
|
||||
// registerCommand(Command{Trigger: "echo", Type: CommandTypePrefix, Function: echoMessage})
|
||||
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user