Skip to content

Replace ts.hasOwnProperty.call(...) with hasProperty(...) #49410

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

Merged
merged 1 commit into from
Jun 7, 2022

Conversation

jakebailey
Copy link
Member

This was introduced in #48389; it relies on the fact that ts is an object to get access to this commonly-used helper, but this confuses the module transform into thinking it can actually import this from the TS namespace (I'm working around it for now). Just use the helper we have in core.ts instead.

@typescript-bot typescript-bot added Author: Team For Uncommitted Bug PR for untriaged, rejected, closed or missing bug labels Jun 7, 2022
@jakebailey jakebailey changed the title Replace ts.hasOwnProperty with hasProperty Replace ts.hasOwnProperty.call(...) with hasProperty(...) Jun 7, 2022
@jakebailey jakebailey merged commit f72b1ba into microsoft:main Jun 7, 2022
@jakebailey jakebailey deleted the fix-has-own-property branch June 7, 2022 03:10
@jakebailey
Copy link
Member Author

Thank you!

@weswigham
Copy link
Member

🤦‍♀️ definitely not intentional to use the Object method directly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Author: Team For Uncommitted Bug PR for untriaged, rejected, closed or missing bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants