Skip to content

Commit

Permalink
Office365OAuthService: Restore Accept header in user info request
Browse files Browse the repository at this point in the history
In update of scribe version change: I68717ebb988 Accept header was
inadvertently removed. Restore the setting of Accept header to "*/*":

  request.addHeader("Accept", "*/*");

Bug: Issue davido/gerrit-oauth-provider#144
Change-Id: I224f798c7fb37e24be7f4fecfc29e11932c51286
  • Loading branch information
davido authored and David Ostrovsky committed Jun 30, 2020
1 parent a34aff9 commit fd6f75c
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ public OAuthUserInfo getUserInfo(OAuthToken token) throws IOException {
OAuthRequest request = new OAuthRequest(Verb.GET, PROTECTED_RESOURCE_URL);
OAuth2AccessToken t = new OAuth2AccessToken(token.getToken(), token.getRaw());
service.signRequest(t, request);
request.addHeader("Accept", "*/*");

JsonElement userJson = null;
try (Response response = service.execute(request)) {
Expand Down

0 comments on commit fd6f75c

Please sign in to comment.