From 2a37690f709391d5bcd4186809046676100bd98f Mon Sep 17 00:00:00 2001 From: James Roome Date: Thu, 20 Feb 2014 16:06:52 -0600 Subject: docs(ngSubmit): reference correct object ($scope) in example. Switched from this to $scope. It's confusing using $scope and this interchangeably. Closes #6375 --- src/ng/directive/ngEventDirs.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ng/directive/ngEventDirs.js b/src/ng/directive/ngEventDirs.js index ea65be90..191f67cb 100644 --- a/src/ng/directive/ngEventDirs.js +++ b/src/ng/directive/ngEventDirs.js @@ -313,9 +313,9 @@ forEach( $scope.list = []; $scope.text = 'hello'; $scope.submit = function() { - if (this.text) { - this.list.push(this.text); - this.text = ''; + if ($scope.text) { + $scope.list.push(this.text); + $scope.text = ''; } }; } -- cgit v1.2.3