Accept user in CreateToken
This commit is contained in:
1 parent
e955638510
commit
b5114beacf
3 files changed
+8
-5
No files matched your search
+1
-1
@@ -118,7 +118,7 @@ func (h *Handler) loginPost(c *gin.Context) {
|
||||
return
|
||||
}
|
||||
|
||||
t, err := h.TokenVerifier.CreateToken(user.Email, user.Name)
|
||||
t, err := h.TokenVerifier.CreateToken(user)
|
||||
if err != nil {
|
||||
c.AbortWithStatus(http.StatusUnauthorized)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user