Skip to content

Commit

Permalink
Merge pull request #43 from LyricTian/develop
Browse files Browse the repository at this point in the history
validation bearer token add error return
  • Loading branch information
LyricTian authored Nov 17, 2016
2 parents c4bf274 + ba02938 commit 612d8b4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -510,9 +510,9 @@ func (s *Server) BearerAuth(r *http.Request) (accessToken string, ok bool) {
func (s *Server) ValidationBearerToken(r *http.Request) (ti oauth2.TokenInfo, err error) {
accessToken, ok := s.BearerAuth(r)
if !ok {
err = errors.ErrInvalidAccessToken
return
}

ti, err = s.Manager.LoadAccessToken(accessToken)

return
Expand Down

0 comments on commit 612d8b4

Please sign in to comment.