From 323449973b12db3934cfc5cd30e8436fb72bec03 Mon Sep 17 00:00:00 2001 From: Lee Elenbaas Date: Tue, 21 Jan 2014 12:01:31 +0200 Subject: [PATCH 1/3] Make equals recursuve calls use the public API --- src/Angular.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Angular.js b/src/Angular.js index 21ce1ff7282d..70cf3fdb0834 100644 --- a/src/Angular.js +++ b/src/Angular.js @@ -820,7 +820,7 @@ function equals(o1, o2) { if (!isArray(o2)) return false; if ((length = o1.length) == o2.length) { for(key=0; key Date: Tue, 21 Jan 2014 12:32:56 +0200 Subject: [PATCH 2/3] Call global API --- src/Angular.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Angular.js b/src/Angular.js index 70cf3fdb0834..0de8dcaa81da 100644 --- a/src/Angular.js +++ b/src/Angular.js @@ -820,7 +820,7 @@ function equals(o1, o2) { if (!isArray(o2)) return false; if ((length = o1.length) == o2.length) { for(key=0; key Date: Tue, 21 Jan 2014 18:10:15 +0200 Subject: [PATCH 3/3] Use the API compile inside scope & compile --- src/ng/compile.js | 2 +- src/ng/rootScope.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ng/compile.js b/src/ng/compile.js index dd47ca3bc080..f98bf468dfc6 100644 --- a/src/ng/compile.js +++ b/src/ng/compile.js @@ -1427,7 +1427,7 @@ function $CompileProvider($provide, $$sanitizeUriProvider) { } parentGet = $parse(attrs[attrName]); if (parentGet.literal) { - compare = equals; + compare = angular.equals; } else { compare = function(a,b) { return a === b; }; } diff --git a/src/ng/rootScope.js b/src/ng/rootScope.js index bbf290b2909a..3dfa44ad6761 100644 --- a/src/ng/rootScope.js +++ b/src/ng/rootScope.js @@ -589,7 +589,7 @@ function $RootScopeProvider(){ if (watch) { if ((value = watch.get(current)) !== (last = watch.last) && !(watch.eq - ? equals(value, last) + ? angular.equals(value, last) : (typeof value == 'number' && typeof last == 'number' && isNaN(value) && isNaN(last)))) { dirty = true;