diff --git a/src/ng/parse.js b/src/ng/parse.js index b2ef9f27d4e4..f173eed527d8 100644 --- a/src/ng/parse.js +++ b/src/ng/parse.js @@ -1907,7 +1907,7 @@ function $ParseProvider() { if (isDone(lastValue)) { scope.$$postDigest(unwatchIfDone); } - return post(lastValue, scope, locals); + return post(lastValue); } } diff --git a/test/ng/parseSpec.js b/test/ng/parseSpec.js index 8e6b6a943634..7c5baad1630b 100644 --- a/test/ng/parseSpec.js +++ b/test/ng/parseSpec.js @@ -3246,6 +3246,20 @@ describe('parser', function() { expect(args).toEqual([1]); })); + it('should only be passed the intercepted value when wrapping one-time', inject(function($parse) { + var args; + function interceptor(v) { + args = sliceArgs(arguments); + return v; + } + + scope.$watch($parse('::a', interceptor)); + + scope.a = 1; + scope.$digest(); + expect(args).toEqual([1]); + })); + it('should only be passed the intercepted value when double-intercepted', inject(function($parse) { var args1;