title: ng-model is undefined in controller
body: <p>I'm using ionic and I have the following view:</p>
  
  <pre><code>&lt;ion-view hide-nav-bar="true" ng-controller="loginController" class="login-view"&gt;
    &lt;ion-content class="padding"&gt;
  
      &lt;div class="row row-center"&gt;
        &lt;div class="col"&gt;
  
          &lt;div id="logo"&gt;&lt;/div&gt;
  
          &lt;form&gt;
            &lt;div class="list"&gt;
              &lt;label class="item item-input"&gt;
                &lt;input type="text" placeholder="Membership No" ng-model="membershipNo"&gt;
              &lt;/label&gt;
              &lt;label class="item item-input"&gt;
                &lt;input type="password" placeholder="Password" ng-model="password"&gt;
              &lt;/label&gt;
            &lt;/div&gt;
  
            &lt;button class="button button-block button-positive button-login" ng-click="login()"&gt;
              Login
            &lt;/button&gt;
          &lt;/form&gt;
  
        &lt;/div&gt;
      &lt;/div&gt;
  
    &lt;/ion-content&gt;
  &lt;/ion-view&gt;
  </code></pre>
  
  <p>And my controller:</p>
  
  <pre><code>app.controller('loginController', ['$scope', '$localstorage',
      function($scope, $localstorage) {
  
          $scope.membershipNo;
          $scope.password;
  
          $scope.login = function () {
              console.log("User logged in with membership no: " + $scope.membershipNo +
      "\n and password: " + $scope.password);
          }
  
      }
  ]);
  </code></pre>
  
  <p>What I don't understand, is that when I click the button, the login function is called correctly. Also, if in the controller I go and set <code>$scope.membershipNo</code> to something like "Banana Pancake", the view actually updates.</p>
  
  <p>Yet when the login function actually runs, is says that membershipNo and password are undefined. I'm fairly new to Angular and Ionic so I know this is probably some n00b mistake...</p>