Skip to content

Conversation

@jimmyjames
Copy link
Contributor

The documentation for a claim's asString() method is misleading. We don't return the toString() result of all underlying claim types, as the JavaDoc's somewhat currently imply. Instead, we check if it is a text-based claim (i.e., a string) before returning its textual value.

Perhaps in the future we should just get the textual value regardless of underlying type, but that could have impact on clients relying on the null return values for non-string based claims.

This change updates the docs to reflect the actual behavior.

Closes #614

@jimmyjames jimmyjames merged commit 9840e74 into master Oct 15, 2022
@jimmyjames jimmyjames deleted the iss-614 branch October 15, 2022 01:37
@jimmyjames jimmyjames mentioned this pull request Oct 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Claim asString returns null for types with valid string representations

3 participants