refactor($animate): speed up animationsDisabled check

This commit is contained in:
Igor Minar 2013-11-06 15:01:01 -08:00
parent 1df3da361d
commit 5cfacec499

View file

@ -754,6 +754,8 @@ angular.module('ngAnimate', ['ng'])
}
function animationsDisabled(element, parentElement) {
if (rootAnimateState.disabled) return true;
if(element[0] == $rootElement[0]) {
return rootAnimateState.disabled || rootAnimateState.running;
}