title: How to get the status code from DS.InvalidError and DS.AdapterError?
body: <p>Currently in the process of upgrading quite a large EmberJS app all the way from 1.7 to 1.13 (and then 2.0 later). We're pretty much there now. </p>
  
  <p>We handle errors from the server differently depending on the HTTP status code. Our current code goes a little like this... </p>
  
  <pre><code>model.save().then(
      // Success
      function() { /* ... */ },
      // Failure
      function(response) {
          switch (response.status) {
              case 403:
                  /* ... */ 
              case 422:
                   /* ... */ 
              case 500:
                   /* ... */ 
              default:
                   /* ... */ 
  
          }
      }
  )
  </code></pre>
  
  <p>Previously, we could just get the status code from the <code>status</code> attribute. Now, that doesn't exist because the <code>response</code> variable is an instance of DS.InvalidError or DS.AdapterError.</p>
  
  <p><strong>Question</strong></p>
  
  <p>How can we get the status code?</p>
  
  <p>Alternatively, how can we distinguish between the different possible response classes (<code>DS.InvalidError</code> and <code>DS.AdapterError</code>)?</p>
  
  <p><strong>Versions</strong></p>
  
  <ul>
  <li>Ember: 1.13.6</li>
  <li>Ember Data: 1.13.7</li>
  </ul>