jQuery's .then() not executing onFailure function even though GET request encountered an error
<p>I am trying to convince <a href="http://api.jquery.com/deferred.then/" rel="nofollow">.then()</a> to execute it's failure condition.</p>

<p>I have the following. Note that taskID has been replaced with -1 to induce failure.</p>

<pre><code>load: function (taskID) {
    $.when(
        $('#OrderDetails').load('../../csweb/Orders/OrderDetails'),
        $('#TaskDetails').load('../../csweb/Orders/TaskDetails/?taskID=' + -1),
        $('#DeviceDetails').load('../../csweb/Orders/DeviceDetails'),
        $('#Provisioning').load('../../csweb/Orders/Provisioning'),
        $('#Activity').load('../../csweb/Orders/Activity')
    ).then(onDisplayLoadSuccess, onDisplayLoadFailure);
}

var onDisplayLoadSuccess = function () {
    console.log("onDisplayLoadSuccess!");
};

var onDisplayLoadFailure = function () {
    console.log("onDisplayLoadFailure!");
};
</code></pre>

<p><img src="http://i.stack.imgur.com/7bqOo.png" alt="enter image description here"></p>

<p>From <a href="http://api.jquery.com/jQuery.when/" rel="nofollow">documentation of .when()</a>:</p>

<blockquote>
  <p>In the case where multiple Deferred objects are passed to jQuery.when, the method returns the Promise from a new "master" Deferred object that tracks the aggregate state of all the Deferreds it has been passed. The method will resolve its master Deferred as soon as all the Deferreds resolve, or <strong>reject the master Deferred as soon as one of the Deferreds is rejected</strong>.</p>
</blockquote>

<p>Since one of my load requests fails -- shouldn't then be executing onDisplayLoadFailure?</p>
