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

[BUGFIX release] On re-render, ensure child views of non-dirty components get the correct parentView #11651

Merged
merged 1 commit into from
Jul 6, 2015

Conversation

jder
Copy link
Contributor

@jder jder commented Jul 4, 2015

This is quite possibly a bad hack rather than a nice solution. I'd love suggestions for a cleaner approach.

On re-render of a non-dirty component, the env was simply passed down when
rendering the component's template, which means its parentView was wrong; this
patch mimics what keywords already do to solve this for components.

Fixes #11554

…ents get the correct parentView

On re-render of a non-dirty component, the `env` was simply passed down when
rendering the component's template, which means its parentView was wrong; this
patch mimics what keywords already do to solve this for components.

Fixes emberjs#11554
@stefanpenner
Copy link
Member

rerunning tests

@stefanpenner
Copy link
Member

@tomdale would love for your eyes on this.

@rwjblue
Copy link
Member

rwjblue commented Jul 4, 2015

Agreed. Would definitely like @tomdale or @wycats review.

@tomdale
Copy link
Member

tomdale commented Jul 6, 2015

This actually seems like a totally legit use case for the buildChildEnv hook to me—cases where you need to fixup the child env but your render node may not be dirty.

@rwjblue
Copy link
Member

rwjblue commented Jul 6, 2015

@tomdale - So you are 👍?

@tomdale
Copy link
Member

tomdale commented Jul 6, 2015

It's extremely reminiscent of the issue with outlets but admittedly I am a little out-of-context at the moment.

I have not carefully investigated but I can see why there could be an issue here. I'm comfortable with the fix if the test passed and no other tests regress.

stefanpenner added a commit that referenced this pull request Jul 6, 2015
[BUGFIX release] On re-render, ensure child views of non-dirty components get the correct parentView
@stefanpenner stefanpenner merged commit c3accfb into emberjs:stable Jul 6, 2015
@jder
Copy link
Contributor Author

jder commented Jul 6, 2015

Thanks, all. Is there anything more I should do to get this into 2.0 as well, or does stable get merged into master regularly?

@mixonic
Copy link
Member

mixonic commented Jul 6, 2015

@jder [BUGFIX release] goes into the current release (1.13.x) as well as beta and master. You can see contributing to Ember.js for more details about how commit tagging works.

@jder
Copy link
Contributor Author

jder commented Jul 6, 2015

Ah! I made this to stable rather than master. (cc @rwjblue; this should apply to both master and stable) I had found the contributing doc in the repo, but not in the guide, sorry!

@rwjblue
Copy link
Member

rwjblue commented Jul 6, 2015

@jder - No worries, I'll pull it into beta and master branches now.

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.

5 participants