Skip to content

Commit b5195b8

Browse files
committed
changed the eval for ie to be able to return a function
1 parent 1f05621 commit b5195b8

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/Scope.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ function getterFn(path){
7272
}
7373
});
7474
code += ' return self;\n}';
75-
fn = eval('(' + code + ')');
76-
fn.toString = function(){ return code; };
75+
fn = eval('fn = ' + code);
76+
fn["toString"] = function(){ return code; };
7777

7878
return getterFnCache[path] = fn;
7979
}

test/testabilityPatch.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ function sortedHtml(element) {
8181
attr.name !='style' &&
8282
attr.name.substr(0, 6) != 'jQuery') {
8383
// in IE we need to check for all of these.
84-
if (!/ng:\d+/.exec(attr.name))
84+
if (!/ng-\d+/.exec(attr.name))
8585
attrs.push(' ' + attr.name + '="' + attr.value + '"');
8686
}
8787
}

0 commit comments

Comments
 (0)