Skip to content

Commit

Permalink
fix appleboy#82, add the code reply with login and refresh (appleboy#97)
Browse files Browse the repository at this point in the history
  • Loading branch information
kweisamx authored and appleboy committed Dec 5, 2017
1 parent d16975b commit 2b44830
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions auth_jwt.go
Original file line number Diff line number Diff line change
Expand Up @@ -280,6 +280,7 @@ func (mw *GinJWTMiddleware) LoginHandler(c *gin.Context) {
}

c.JSON(http.StatusOK, gin.H{
"code": http.StatusOK,
"token": tokenString,
"expire": expire.Format(time.RFC3339),
})
Expand Down Expand Up @@ -320,6 +321,7 @@ func (mw *GinJWTMiddleware) RefreshHandler(c *gin.Context) {
}

c.JSON(http.StatusOK, gin.H{
"code": http.StatusOK,
"token": tokenString,
"expire": expire.Format(time.RFC3339),
})
Expand Down

0 comments on commit 2b44830

Please sign in to comment.