title: Rails request.xhr? returns 0
body: <p>I'm trying to detect whether request is xhr or not in ApplicationController by using</p>
  
  <pre><code>request.xhr?
  </code></pre>
  
  <p>It always returns 0. </p>
  
  <p>But headers tell otherwise;</p>
  
  <pre><code>request.headers["X-Requested-With"]  ==&gt; "XMLHttpRequest"
  @_env['HTTP_X_REQUESTED_WITH'] ==&gt; "XMLHttpRequest"
  </code></pre>
  
  <p>What am I missing?</p>
  
  <p>version is Rails 4.0.0</p>