title: Restrictions of XMLHttpRequest's getResponseHeader()?
body: <p>I've noticed that the results of and <code>XMLHttpRequest.getResponseHeader()</code> don't always match the real headers returned (if the request is made in a regular manner).</p>
  
  <p>For example, assume I'm making an <code>xhr</code> request for <code>https://foo.example.com/api/resource/100</code>. In Chrome's developer console, under 'Network', I can see the response being made -- I can also see all of the response headers (say, 10). However (copy-pasted console):</p>
  
  <pre><code>&gt; response
    XMLHttpRequest
  &gt; response.getAllResponseHeaders();
    "content-type: text/html
    " 
  </code></pre>
  
  <p>Are there any restrictions on what headers are available? Is this dependent on the response type? I remember getting a complete set of headers for 404s but just this one for 400s.</p>
  
  <p>What gives?</p>