We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a92f4f0 + c2d369d commit 9a4ba4aCopy full SHA for 9a4ba4a
api/auth.go
@@ -148,14 +148,14 @@ func login(c *gin.Context) {
148
userEntry, err := database.QueryFirstUserEntry("username", username)
149
150
if err != nil {
151
- c.JSON(http.StatusUnauthorized, HTTPPlainResp{
+ c.JSON(http.StatusBadRequest, HTTPPlainResp{
152
Message: err.Error(),
153
})
154
return
155
}
156
157
if userEntry.Status == 1 {
158
+ c.JSON(http.StatusForbidden, HTTPPlainResp{
159
Message: "The user has been banned from this competition. Please contact competition admin for more information",
160
161
0 commit comments