We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
enum values with 0 are decoded incorrectly.
message AccountAccess { enum AccessStatus { INACTIVE = 0; PENDING = 1; ACTIVE = 2; } AccessStatus status = 1; }
if (message.status !== 0) { obj.status = accountAccess_AccessStatusToJSON(message.status); }
An inactive value is decoded as undefined instead of INACTIVE.
undefined
INACTIVE
The text was updated successfully, but these errors were encountered:
It's part of the protobuf3 JSON spec that default values can/should be left out of the JSON:
https://protobuf.dev/programming-guides/proto3/#json
But there is also a emitDefaultValues=json-methods flag if you don't like that behavior.
emitDefaultValues=json-methods
Sorry, something went wrong.
No branches or pull requests
enum values with 0 are decoded incorrectly.
An inactive value is decoded as
undefined
instead ofINACTIVE
.The text was updated successfully, but these errors were encountered: