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] Fix #13670 #13672

Merged
merged 1 commit into from
Jun 15, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions packages/ember-routing/lib/system/route.js
Original file line number Diff line number Diff line change
Expand Up @@ -2030,9 +2030,13 @@ var Route = EmberObject.extend(ActionHandler, Evented, {
// into its outlets, which won't render anywhere. All of this
// statefulness should get the machete in 2.0.
this.connections[i] = {
owner: connection.owner,
into: connection.into,
outlet: connection.outlet,
name: connection.name
name: connection.name,
controller: undefined,
template: undefined,
ViewClass: undefined
};
run.once(this.router, '_setOutlets');
}
Expand Down Expand Up @@ -2130,7 +2134,8 @@ function buildRenderOptions(route, namePassed, isDefaultRender, _name, options)
outlet,
name,
controller,
template: template || route._topLevelViewTemplate
template: template || route._topLevelViewTemplate,
ViewClass: undefined
};

assert(`Could not find "${name}" template, view, or component.`, isDefaultRender || template);
Expand Down
8 changes: 8 additions & 0 deletions packages/ember/tests/routing/basic_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -2439,6 +2439,14 @@ test('Route supports clearing outlet explicitly', function() {
router.send('hideExtra');
});
equal(jQuery('div.posts-extra:contains(postsExtra)', '#qunit-fixture').length, 0, 'The posts/extra template was removed');
run(function() {
router.send('showModal');
});
equal(jQuery('div.posts-modal:contains(postsModal)', '#qunit-fixture').length, 1, 'The posts/modal template was rendered');
run(function() {
router.send('showExtra');
});
equal(jQuery('div.posts-extra:contains(postsExtra)', '#qunit-fixture').length, 1, 'The posts/extra template was rendered');

handleURL('/users');

Expand Down