We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fee0bf0 commit b8df1f8Copy full SHA for b8df1f8
bot/bot.go
@@ -63,7 +63,7 @@ func (bot *AmputatorBot) GuildCreate(s *discordgo.Session, gc *discordgo.GuildCr
63
// message is created on any channel that the authenticated bot has access to.
64
func (bot *AmputatorBot) MessageCreate(s *discordgo.Session, m *discordgo.MessageCreate) {
65
// This is a message the bot created itself
66
- if m.Author.ID == s.State.User.ID {
+ if m.Author != nil && s.State.User != nil && m.Author.ID == s.State.User.ID {
67
bot.createMessageEvent("", m.Message)
68
return
69
}
0 commit comments