From 1e8297be437d3a6b0c0f32d6f575f238c69649f1 Mon Sep 17 00:00:00 2001 From: Wesley Cho Date: Sun, 2 Aug 2015 00:14:21 -0700 Subject: [PATCH] fix(modal): properly garbage collect DOM node - Garbage collect using `$animate` so that `$animate` releases reference to DOM node Fixes #2875 --- src/modal/modal.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modal/modal.js b/src/modal/modal.js index eadc44e777..784688b92a 100644 --- a/src/modal/modal.js +++ b/src/modal/modal.js @@ -279,7 +279,7 @@ angular.module('ui.bootstrap.modal', []) } afterAnimating.done = true; - domEl.remove(); + $animate.leave(domEl); scope.$destroy(); if (done) { done();