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

fix: make struct types play well with type registry #503

Merged
merged 1 commit into from
Feb 12, 2022

Conversation

aikoven
Copy link
Collaborator

@aikoven aikoven commented Feb 10, 2022

With type registry enabled, the code generated from struct.proto would not compile due to missing $type field.

In this PR all objects are initialized using createBase<Type> function.

I also replaced Struct.fromPartial({}) with createBaseStruct(), because fromPartial can be disabled.

Copy link
Owner

@stephenh stephenh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Thanks!

@stephenh stephenh merged commit d62f854 into stephenh:main Feb 12, 2022
stephenh pushed a commit that referenced this pull request Feb 12, 2022
## [1.104.1](v1.104.0...v1.104.1) (2022-02-12)

### Bug Fixes

* make struct types play well with type registry ([#503](#503)) ([d62f854](d62f854))
@stephenh
Copy link
Owner

🎉 This PR is included in version 1.104.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@aikoven aikoven deleted the fix-struct-types branch February 12, 2022 02:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants