From f711c846013c514724126d2043d761bb3059861d Mon Sep 17 00:00:00 2001 From: wilgert Date: Wed, 15 Oct 2014 21:06:58 +0200 Subject: [PATCH] Update animate.js Check if cache and cache.classes exist. Sometimes cache is undefined and errors are thrown when looped over. --- src/ngAnimate/animate.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/ngAnimate/animate.js b/src/ngAnimate/animate.js index 1492576ede01..45549cad60a7 100644 --- a/src/ngAnimate/animate.js +++ b/src/ngAnimate/animate.js @@ -549,6 +549,7 @@ angular.module('ngAnimate', ['ng']) } function resolveElementClasses(element, cache, runningAnimations) { + if (!cache || !cache.classes) return; runningAnimations = runningAnimations || {}; var lookup = {};