Skip to content

Commit

Permalink
Merge pull request #33 from wneessen/fix/32_panic-in-register-slashcmd
Browse files Browse the repository at this point in the history
Fix #32
  • Loading branch information
wneessen authored Nov 26, 2022
2 parents 50b4369 + 8c6c5a9 commit 20602cb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions bot/sc_handler_register.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ import (

// SlashCmdRegister handles the /register slash command
func (b *Bot) SlashCmdRegister(s *discordgo.Session, i *discordgo.InteractionCreate) error {
if i.Member == nil || i.Member.User == nil {
return ErrUserNil
}
u, err := b.Model.User.GetByUserID(i.Member.User.ID)
if err != nil && !errors.Is(err, model.ErrUserNotExistent) {
return err
Expand Down
2 changes: 1 addition & 1 deletion bot/version.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
package bot

const Version = "0.2.6"
const Version = "0.2.7"

0 comments on commit 20602cb

Please sign in to comment.