Fix vetting command
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
This commit is contained in:
parent
3cc0003d65
commit
a7b747ebcb
@ -37,7 +37,7 @@ func VettingReqUserID(guildID, msgID string) (string, error) {
|
|||||||
return out, err
|
return out, err
|
||||||
}
|
}
|
||||||
|
|
||||||
func RemoveVettingReq(guildID, msgID string) error {
|
func RemoveVettingReq(guildID, userID string) error {
|
||||||
_, err := db.Exec("DELETE FROM vetting_requests WHERE msg_id = ? AND guild_id = ?", msgID, guildID)
|
_, err := db.Exec("DELETE FROM vetting_requests WHERE user_id = ? AND guild_id = ?", userID, guildID)
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -137,7 +137,7 @@ func approveCmd(s *discordgo.Session, i *discordgo.InteractionCreate) error {
|
|||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
err = db.RemoveVettingReq(i.GuildID, i.Message.ID)
|
err = db.RemoveVettingReq(i.GuildID, user.ID)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user