Fix JSON output serialization issue.