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(document): Set Document.modelName property in constructor #12682

Merged
merged 1 commit into from Nov 12, 2022

Conversation

lpizzinidev
Copy link
Contributor

@lpizzinidev lpizzinidev commented Nov 11, 2022

fix #12669

Copy link
Collaborator

@vkarpov15 vkarpov15 left a comment

Choose a reason for hiding this comment

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

I think the more correct fix here would be to remove modelName from the Document class in the TS definitions. This is a case where the TypeScript type defs are incorrect, and it would require a little more work to make our runtime behavior match the defined types.

Copy link
Collaborator

@vkarpov15 vkarpov15 left a comment

Choose a reason for hiding this comment

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

Thanks 👍

@vkarpov15 vkarpov15 added this to the 6.7.3 milestone Nov 12, 2022
@vkarpov15 vkarpov15 merged commit ab71536 into Automattic:master Nov 12, 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.

Document.modelName type definition is string, but get undefined at runtime
2 participants