Skip to content

Commit

Permalink
bug fix.
Browse files Browse the repository at this point in the history
  • Loading branch information
yildizsc committed Dec 10, 2023
1 parent 1c78680 commit e241b5f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
6 changes: 6 additions & 0 deletions src/main/java/com/webex/events/ErrorResponse.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,15 @@

public class ErrorResponse {
public String message;
public JsonNode errors;

public JsonNode extensions;

public String getCode() {
if (extensions == null) {
return "";
}

return extensions.get("code").textValue();
}

Expand Down
3 changes: 2 additions & 1 deletion src/main/java/com/webex/events/RateLimiter.java
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,9 @@ int getSecondlyRetryAfter() {
private String getHeaderValue(String header) {
String headerValue = "";

if (!headers.allValues(header).isEmpty()) {
try {
headerValue = headers.allValues(header).get(0);
}catch (ArrayIndexOutOfBoundsException ignored) {
}
return headerValue;
}
Expand Down

0 comments on commit e241b5f

Please sign in to comment.