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(entry): fix a bug when --display-entrypoints=false does not hide entries #464

Merged
merged 3 commits into from May 30, 2018

Conversation

sfger
Copy link
Contributor

@sfger sfger commented May 24, 2018

What kind of change does this PR introduce?
Fix bug: #463

Did you add tests for your changes?
Yes
If relevant, did you update the documentation?
No
Summary
Fix bug: #463

Does this PR introduce a breaking change?
NO

Other information

@jsf-clabot
Copy link

jsf-clabot commented May 24, 2018

CLA assistant check
All committers have signed the CLA.

@ematipico
Copy link
Contributor

Just out of curiosity, what was the value of bool when you debugged the code?

bin/webpack.js Outdated
@@ -357,7 +357,7 @@ For more information, see https://webpack.js.org/api/cli/.`);
});

ifArg("display-entrypoints", function(bool) {
if (bool) outputOptions.entrypoints = true;
outputOptions.entrypoints = !!bool;
Copy link
Member

Choose a reason for hiding this comment

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

Double boolean trick is enough to flip it correctly. Used it myself, but it might be some pitfalls, so might be better to do a strict equal instead if (bool === true)

Copy link
Contributor Author

@sfger sfger May 24, 2018

Choose a reason for hiding this comment

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

Yes, The trick is redundant。
The param:bool is true or false anyhow!

@ematipico
Copy link
Contributor

Could we add a test?

Copy link
Contributor

@ematipico ematipico left a comment

Choose a reason for hiding this comment

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

Thanks!!

Copy link
Member

@dhruvdutt dhruvdutt left a comment

Choose a reason for hiding this comment

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

Thanks for your contributions. 🎉

@webpack-bot
Copy link

Hi @sfger.

Just a little hint from a friendly bot about the best practice when submitting pull requests:

Don't submit pull request from your own master branch. It's recommended to create a feature branch for the PR.

You don't have to change it for this PR, just make sure to follow this hint the next time you submit a PR.

@sfger
Copy link
Contributor Author

sfger commented May 25, 2018

@webpack-bot:
Sure~ That's a good way!

@evenstensberg evenstensberg changed the title fix: fix a buy when --display-entrypoints=false does not hide entries fix(entries): fix a buy when --display-entrypoints=false does not hide entries May 25, 2018
@evenstensberg evenstensberg changed the title fix(entries): fix a buy when --display-entrypoints=false does not hide entries fix(entry): fix a buy when --display-entrypoints=false does not hide entries May 25, 2018
@evenstensberg evenstensberg changed the title fix(entry): fix a buy when --display-entrypoints=false does not hide entries fix(entry): fix a bug when --display-entrypoints=false does not hide entries May 30, 2018
@evenstensberg evenstensberg merged commit c2398a2 into webpack:master May 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants