Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stleary#838 - Fix enum serialization in JSONObject #839

Closed

Conversation

ThestralWarrior
Copy link

Resolves an issue where JSONObject.toString() used Enum.name() instead of Enum.toString() when serializing enum values. Updated the relevant code in JSONObject to use the overridden toString() method for enum values.

…ridden toString() method for enum values instead of name().
@johnjaylward
Copy link
Contributor

Enum.name is correct. This PR is introducing a bug

@stleary
Copy link
Owner

stleary commented Dec 15, 2023

Closing due to failed unit tests.
@ThestralWarrior Thanks for the PR, but it looks like it cannot be accepted, for the reason cited by @johnjaylward.
Developers who wish to submit pull requests are strongly encouraged to run the unit tests first, using Gradle or Maven:
gradlew clean build test
Or:
mvn clean compile test

@stleary stleary closed this Dec 15, 2023
@ThestralWarrior ThestralWarrior deleted the fix/issue-838 branch December 15, 2023 08:38
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.

3 participants