title: confirm use of jQuery.ajaxSettings.xhr
body: <pre><code>var _orgAjax = jQuery.ajaxSettings.xhr;
  jQuery.ajaxSettings.xhr = function () {
      var xhr = _orgAjax();
      DoSomeLogging();
      return xhr;
  };
  </code></pre>
  
  <p>I've inherited the code above. Can someone confirm my understanding that this will override any <code>$.ajax(...)</code> call anywhere else on the page and execute <code>DoSomeLogging()</code> each time?</p>
  
  <p>I'm hunting a different bug but stumbled upon this and wanted to be sure I understand what this piece of legacy code does? </p>
  
  <p>I'm not convinced this is good practice/use of the <code>xhr</code> function anyway but interested to hear your opinions. We're using Jquery 1.7.1.</p>
  
  <p>Lastly, out of curiosity, what if <code>_orgAjax()</code> failed to return if an (<code>async: false</code>) call, would the logging method even get reached?</p>
  
  <p>Thanks.</p>