First merge from develop to main (WIP) #7

Merged
sugar merged 199 commits from develop into main 2026-01-27 17:47:07 +00:00
Showing only changes of commit fd1c89392f - Show all commits

View File

@@ -15,11 +15,13 @@ func JWTAuth(required bool) gin.HandlerFunc {
uid, err := token.HeaderVerify(auth)
if err != nil {
c.JSON(401, gin.H{"status": err.Error()})
c.Abort()
return
}
if required == true && uid == "" {
c.JSON(401, gin.H{"status": "unauthorized"})
c.Abort()
return
}