Commit 18bf8aad by StageDog

fix: IsDiscordIdAlreadyTaken 应该检查软删除记录

parent cf8d4e87
......@@ -588,7 +588,7 @@ func IsGitHubIdAlreadyTaken(githubId string) bool {
}
func IsDiscordIdAlreadyTaken(discordId string) bool {
return DB.Where("discord_id = ?", discordId).Find(&User{}).RowsAffected == 1
return DB.Unscoped().Where("discord_id = ?", discordId).Find(&User{}).RowsAffected == 1
}
func IsOidcIdAlreadyTaken(oidcId string) bool {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment