-
Notifications
You must be signed in to change notification settings - Fork 38
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
Remove return voids #91
Conversation
if ( | ||
returnStatement.argument.operator === 'void' && returnStatement.argument.argument.raw === '0' || | ||
returnStatement.argument.name === 'undefined' | ||
) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have a check for whether something is undefined
or not here: https://github.com/Shopify/javascript/blob/master/packages/shopify-codemod/transforms/coffeescript-soak-to-condition.js#L279-L288, might be worth pulling that out into utils.js
and importing it in both spots.
My comments were mostly minor, the bulk of this looks great 👍 Before merging, make sure to add details about this transform in |
…oved isUndefined to ./utils
New changes looking good @lemonmade? |
Looks like you might have had an issue with the rebase :( |
Fixes pointless else blocks generated by Decaf in #82
/cc @lemonmade @GoodForOneFare