Browse Source

fix: add missing return after sending response

JustSong 2 years ago
parent
commit
b616fc8d84
1 changed files with 1 additions and 0 deletions
  1. 1 0
      middleware/auth.go

+ 1 - 0
middleware/auth.go

@@ -19,6 +19,7 @@ func authHelper(c *gin.Context, minRole int) {
 			"message": "无权进行此操作,未登录",
 		})
 		c.Abort()
+		return
 	}
 	if status.(int) == common.UserStatusDisabled {
 		c.JSON(http.StatusOK, gin.H{