title: TypeError: Cannot read property 'push' of null
body: <p>I made a Todo app with Angularjs and Ionic.
  I want to save to localStorage some fields, but when i click save I get this error.</p>
  
  <p>My code is: </p>
  
  <pre><code>angular.module('myApp', ['ionic'])
      .controller('myAppCtrl', function($scope){
  
          $scope.uuid = function(){
              return Math.floor(( 1 + Math.random()) * 0x10000)
                  .toString(16)
                  .substring(1);
          };
  
          $scope.todo = {};
          $scope.todos = {};
  
          //Check The Localstorage If the Todos exists
          var todos = localStorage.getItem('todos');
  
          if(todos !== undefined){
              $scope.todos = JSON.parse(todos);
          }
  
          $scope.addTodo = function($event){
              activate_page("#create_edit");
          };
  
          $scope.goBack = function($event){
              activate_page("#mainpage");
          };
  
          $scope.saveTodo = function($event){
  
              $scope.todo.id = $scope.uuid();
              $scope.todos.push($scope.todo);
              $scope.todo = {};
              localStorage.setItem('todos', JSON.stringify($scope.todos)); //Save 
              activate_page("#mainpage");            
          };
      });
  </code></pre>
  
  <p>Can you help me?
  Thank you</p>