Skip to content

Commit

Permalink
feat(token): trim pubsub message attribute token with bearer prefix
Browse files Browse the repository at this point in the history
  • Loading branch information
romain-jeannoutot committed Apr 20, 2022
1 parent 61804c2 commit 3ba56f1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion token.go
Original file line number Diff line number Diff line change
Expand Up @@ -137,5 +137,5 @@ func RetrieveTokenFromPubSubMessageAttribute(r *http.Request) (string, error) {
return "", ErrMissingAuthorization
}

return token, nil
return strings.TrimPrefix(token, authorizationPrefix), nil
}

0 comments on commit 3ba56f1

Please sign in to comment.