Skip to content

Commit c03e301

Browse files
committed
feat: log the exception for json processing
1 parent 8c4898d commit c03e301

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/main/java/dev/openfga/sdk/errors/FgaError.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,8 @@ public static Optional<FgaError> getError(
9494
error.setApiErrorCode(resp.code);
9595
error.setApiErrorMessage(resp.message);
9696
} catch (JsonProcessingException e) {
97-
// Fall back, do nothing
97+
// Fall back, do nothing - log the exception for debugging
98+
System.err.println("Failed to parse API error response JSON: " + e.getMessage());
9899
}
99100
}
100101

0 commit comments

Comments
 (0)