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

Remove redundant use strict (Fix #542) #553

Merged
merged 1 commit into from
May 27, 2017
Merged

Remove redundant use strict (Fix #542) #553

merged 1 commit into from
May 27, 2017

Conversation

boopathi
Copy link
Member

No description provided.

@codecov
Copy link

codecov bot commented May 24, 2017

Codecov Report

Merging #553 into master will increase coverage by 0.04%.
The diff coverage is 83.33%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #553      +/-   ##
==========================================
+ Coverage   82.89%   82.93%   +0.04%     
==========================================
  Files          40       41       +1     
  Lines        2719     2743      +24     
  Branches      952      958       +6     
==========================================
+ Hits         2254     2275      +21     
- Misses        281      282       +1     
- Partials      184      186       +2
Impacted Files Coverage Δ
...l-plugin-minify-dead-code-elimination/src/index.js 85.5% <100%> (+0.1%) ⬆️
...ify-dead-code-elimination/src/remove-use-strict.js 80% <80%> (ø)
packages/babel-plugin-minify-simplify/src/index.js 80.74% <0%> (+0.12%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ca00355...85bd8ac. Read the comment docs.

@boopathi boopathi added the Tag: New Feature Pull Request adding a new feature label May 24, 2017
* @param {NodePath} block BlockStatement
*/
function removeUseStrict(block) {
if (!block.isBlockStatement()) {
Copy link
Member

Choose a reason for hiding this comment

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

why is this check even needed if its already checked before.

Copy link
Member Author

Choose a reason for hiding this comment

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

since it is a separate file. to not shoot ourselves in foot by calling removeUseStrict(SomeOtherPath)

Copy link
Member

Choose a reason for hiding this comment

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

Cool! didn't realise it was a separate module.

@boopathi boopathi merged commit be3f3a7 into master May 27, 2017
@boopathi boopathi deleted the use-strict-0 branch May 27, 2017 20:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Tag: New Feature Pull Request adding a new feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants