Skip to content

Commit

Permalink
Provide error description in android (#751)
Browse files Browse the repository at this point in the history
Co-authored-by: Rita Zerrizuela <[email protected]>
  • Loading branch information
poovamraj and Widcket authored Oct 5, 2023
1 parent 672215f commit 80c4d26
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion android/src/main/java/com/auth0/react/A0Auth0Module.java
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,8 @@ private void handleError(AuthenticationException error, Promise promise) {
promise.reject("a0.session.invalid_idtoken", "Error validating ID Token", error);
return;
}
promise.reject(error.getCode(), error.getMessage(), error);
String separator = error.getMessage().endsWith(".") ? "" : ".";
promise.reject(error.getCode(), error.getMessage() + separator + " CAUSE: " + error.getDescription(), error);
}

@Override
Expand Down

0 comments on commit 80c4d26

Please sign in to comment.