From 6ae7d48fd13dbcfc94cf89bf08bad729eac3330f Mon Sep 17 00:00:00 2001 From: Robin Ward Date: Thu, 5 Jun 2014 15:20:55 -0400 Subject: [PATCH] FIX: Make sure the context of plugin outlets is correct --- .../javascripts/discourse/helpers/plugin-outlet.js.es6 | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/assets/javascripts/discourse/helpers/plugin-outlet.js.es6 b/app/assets/javascripts/discourse/helpers/plugin-outlet.js.es6 index e0f95f575..1467db3d3 100644 --- a/app/assets/javascripts/discourse/helpers/plugin-outlet.js.es6 +++ b/app/assets/javascripts/discourse/helpers/plugin-outlet.js.es6 @@ -75,9 +75,12 @@ function buildConnectorCache() { export default function(connectionName, options) { if (!_connectorCache) { buildConnectorCache(); } + var self = this; if (_connectorCache[connectionName]) { var CustomContainerView = Ember.ContainerView.extend({ - childViews: _connectorCache[connectionName].map(function(vc) { return vc.create(); }) + childViews: _connectorCache[connectionName].map(function(vc) { + return vc.create({context: self}); + }) }); return Ember.Handlebars.helpers.view.call(this, CustomContainerView, options); }