Skip to content

Commit

Permalink
add refresh test
Browse files Browse the repository at this point in the history
  • Loading branch information
kkdai committed Mar 21, 2019
1 parent 8da16ad commit 7677ba3
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions line_login.go
Expand Up @@ -80,7 +80,12 @@ func auth(w http.ResponseWriter, r *http.Request) {
if result, err := socialClient.TokenVerify(token.AccessToken).Do(); err != nil {
log.Println("TokenVerify err:", err, result)
return
}

//Start to refresh token and renew it.
if refresh, err := socialClient.RefreshToken(token.RefreshToken).Do(); err != nil {
log.Println("RefreshToken err:", err, refresh)
return
}

var payload *social.Payload
Expand Down

0 comments on commit 7677ba3

Please sign in to comment.