title: $cookies.putObject not working in angular 1.4
body: <p>I upgraded from angular 1.2 (original code) more recently to 1.3 (which broke the cookies) to 1.4 as of today ($cookieStore is now deprecated infavor of $cookies)</p>
  
  <p>I added a line <code>$cookies.putObject('user', user);</code> but it isn't saved to cookies (i verified in chrome resources tab)</p>
  
  <pre><code>        /**
           * Authenticate user
           *
           * @param  {Object}   user     - login info
           * @param  {Function} callback - optional
           * @return {Promise}
           */
          login: function (user, callback) {
              var cb = callback || angular.noop;
  
              return Session.save({
                  email: user.email,
                  password: user.password
              }, function (user) {
                  $rootScope.currentUser = user;
                  $cookies.putObject('user', user); //does not save
  
                  return cb();
              }, function (err) {
                  return cb(err);
              }).$promise;
          },
  </code></pre>
  
  <p>I put a breakpoint right after the <code>$cookies.putObject</code> and I get <code>undefined</code> when I try <code>$cookies.getObject('user')</code> in chrome console.</p>
  
  <p>This is an issue because now whenever I refresh the page, I lose the logged in user. The <code>Auth.js</code> service has this line up front:</p>
  
  <pre><code>    // Get currentUser from cookie
      $rootScope.currentUser = $cookies.getObject('user') || null;
  </code></pre>