Skip to content

Commit

Permalink
check if scope is null or empty (#111)
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathanlukas authored Oct 16, 2024
1 parent 40138fc commit 1ef7627
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,9 @@ private HttpPost buildRequest() throws URISyntaxException {
formParams.add(new BasicNameValuePair("client_id", jwtCredential.clientId()));
formParams.add(new BasicNameValuePair("client_secret", jwtCredential.clientSecret()));
formParams.add(new BasicNameValuePair("audience", jwtCredential.audience()));
formParams.add(new BasicNameValuePair("scope", jwtCredential.scope()));
if (jwtCredential.scope() != null && !jwtCredential.scope().isEmpty()) {
formParams.add(new BasicNameValuePair("scope", jwtCredential.scope()));
}
httpPost.setEntity(new UrlEncodedFormEntity(formParams));
return httpPost;
}
Expand Down

0 comments on commit 1ef7627

Please sign in to comment.