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

safer type checking #179

Merged
merged 3 commits into from Jan 16, 2019

Conversation

tquetano-netflix
Copy link
Contributor

@tquetano-netflix tquetano-netflix commented Jan 15, 2019

Check for the existence of node.property before comparing node.property.name

Fixes #178

Check for the existence of `node.property` before comparing `node.property.name`
@lencioni
Copy link
Collaborator

Thanks for the fix! Can you please add a test that would have caught this?

@oliviertassinari
Copy link
Owner

Yes, can we add a test so we don't break it again in the future?

@tquetano-netflix
Copy link
Contributor Author

Alright I'll try to recreate ... this was caught by our crazy build system with a lot of nested stuff. Give me a few.

In the scenario where you are importing from another file that has a `createClass` method with no name associated (such as a React abstraction), this can blow up if you have a custom `createReactClassName`.
@tquetano-netflix
Copy link
Contributor Author

Sorry to be pestilent, but now that the fix has tests and is approved and all that jazz ... is there anything blocking its release? We'd like to incorporate this into our build because it will have immediate tangible gains. 😺

@oliviertassinari oliviertassinari merged commit 94bc145 into oliviertassinari:master Jan 16, 2019
@oliviertassinari
Copy link
Owner

@tquetano-netflix Well done! I'm releasing a patch :).

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.

None yet

3 participants