Skip to content

Commit

Permalink
fixes crash
Browse files Browse the repository at this point in the history
  • Loading branch information
Seklfreak committed Jul 9, 2022
1 parent a30b172 commit ab145b9
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion events/keys.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,12 @@ func permissionOverwriteKey(event *discordgo.PermissionOverwrite) string {
}

func messageUpdateKey(event *discordgo.MessageUpdate) string {
return event.ID + event.EditedTimestamp.String()
key := event.ID
if event.EditedTimestamp != nil {
key += event.EditedTimestamp.String()
}

return key
}

func messageReactionKey(event *discordgo.MessageReaction) string {
Expand Down

0 comments on commit ab145b9

Please sign in to comment.