aboutsummaryrefslogtreecommitdiffstats
path: root/src/widgets.js
diff options
context:
space:
mode:
authorMisko Hevery2010-04-12 19:05:39 -0700
committerMisko Hevery2010-04-12 19:05:39 -0700
commit7c49b255483c0381c23de41d108800f93ebc1979 (patch)
tree09c841a413070e3c1eb6d69661f4a344f4a9d556 /src/widgets.js
parent713307b6505a56ca7b5423b36e297070d756ff15 (diff)
downloadangular.js-7c49b255483c0381c23de41d108800f93ebc1979.tar.bz2
$invalid widget clear on switch change
Diffstat (limited to 'src/widgets.js')
-rw-r--r--src/widgets.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/widgets.js b/src/widgets.js
index f5f02813..b281ac2e 100644
--- a/src/widgets.js
+++ b/src/widgets.js
@@ -225,6 +225,8 @@ angularWidget('NG:SWITCH', function ngSwitch(element){
element.append(switchCase.element);
childScope.$tryEval(switchCase.change, element);
switchCase.template(switchCase.element, childScope);
+ if (scope.$invalidWidgets)
+ scope.$invalidWidgets.clearOrphans();
childScope.$init();
}
});