Fixed negative refs #122

Merged
merged 3 commits into from Mar 26, 2017

Conversation

Projects
None yet
4 participants
@tomasAlabes
Contributor

tomasAlabes commented May 11, 2016

Style should be able to be injected if unuse was called more times than use.

myCss.use()
myCss.unuse()
myCss.unuse()

myCss.use() //should be valid, regardless of the double call to unuse

Following the GC idea, there are not "negative" amount of references, just none. Preventing adding more refs makes no sense.
This basically prevents refs from being negative, then the behavior is the same as before.

Fixed negative refs
Makes no sense to not let the style be injected if `unuse` was called more times than `use`.
@tomasAlabes

This comment has been minimized.

Show comment
Hide comment
@tomasAlabes

tomasAlabes Jun 16, 2016

Contributor

@sokra any feedback on this?
Thanks

Contributor

tomasAlabes commented Jun 16, 2016

@sokra any feedback on this?
Thanks

@bebraw

This comment has been minimized.

Show comment
Hide comment
@bebraw

bebraw Mar 6, 2017

Contributor

I would say #176 needs to go in first. After that adding a test for this PR would be possible. 👍

Contributor

bebraw commented Mar 6, 2017

I would say #176 needs to go in first. After that adding a test for this PR would be possible. 👍

@bebraw

This comment has been minimized.

Show comment
Hide comment
@bebraw

bebraw Mar 6, 2017

Contributor

Alright. #176 is in. Please add a test and we'll merge.

Contributor

bebraw commented Mar 6, 2017

Alright. #176 is in. Please add a test and we'll merge.

@tomasAlabes

This comment has been minimized.

Show comment
Hide comment
@tomasAlabes

tomasAlabes Mar 26, 2017

Contributor

@bebraw test is in place. I ran it without my change and it failed, with my change 🚀
Thanks for your work in the loaders guys!

Contributor

tomasAlabes commented Mar 26, 2017

@bebraw test is in place. I ran it without my change and it failed, with my change 🚀
Thanks for your work in the loaders guys!

@michael-ciniawsky michael-ciniawsky merged commit f6f577a into webpack-contrib:master Mar 26, 2017

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
licence/cla Contributor License Agreement is signed.
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment