File tree Expand file tree Collapse file tree 2 files changed +7
-7
lines changed
intercom-java/src/main/java/io/intercom/api Expand file tree Collapse file tree 2 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -227,7 +227,7 @@ private HttpURLConnection prepareConnection(HttpURLConnection conn) {
227227 }
228228
229229 private Map <String , String > createAuthorizationHeaders () {
230- switch (Intercom .getAuthScheme ()) {
230+ switch (Intercom .getAuthKeyType ()) {
231231 case BEARER :
232232 headers .put ("Authorization" , "Bearer " + Intercom .getApiKey ());
233233 break ;
Original file line number Diff line number Diff line change @@ -8,9 +8,9 @@ public class Intercom {
88
99 private static volatile URI apiBaseURI = API_BASE_URI ;
1010
11- private static volatile AuthenticationSchemes authenticationScheme = AuthenticationSchemes .API_KEY ;
11+ private static volatile AuthKeyType authKeyType = AuthKeyType .API_KEY ;
1212
13- enum AuthenticationSchemes {
13+ enum AuthKeyType {
1414 API_KEY ,
1515 BEARER ,
1616 PERSONAL_ACCESS_TOKEN
@@ -81,7 +81,7 @@ public static void setAppID(String appID) {
8181 }
8282
8383 public static void setPersonalAccessToken (String personalAccessToken ) {
84- authenticationScheme = AuthenticationSchemes .PERSONAL_ACCESS_TOKEN ;
84+ authKeyType = AuthKeyType .PERSONAL_ACCESS_TOKEN ;
8585 Intercom .personalAccessToken = personalAccessToken ;
8686 }
8787
@@ -90,7 +90,7 @@ public static String getApiKey() {
9090 }
9191
9292 public static void setApiKey (String apiKey ) {
93- authenticationScheme = AuthenticationSchemes .API_KEY ;
93+ authKeyType = AuthKeyType .API_KEY ;
9494 Intercom .apiKey = apiKey ;
9595 }
9696
@@ -102,8 +102,8 @@ public static void setApiBaseURI(URI apiBaseURI) {
102102 Intercom .apiBaseURI = apiBaseURI ;
103103 }
104104
105- static AuthenticationSchemes getAuthScheme () {
106- return authenticationScheme ;
105+ static AuthKeyType getAuthKeyType () {
106+ return authKeyType ;
107107 }
108108
109109 public static String getPersonalAccessToken () {
You can’t perform that action at this time.
0 commit comments