From: Alexander Ebert Date: Wed, 27 Feb 2013 01:12:18 +0000 (+0100) Subject: Changed API for action proxy's failure method X-Git-Tag: 2.0.0_Beta_1~455 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=c0aaa58844f983163dda809a7a241955ef96cd31;p=GitHub%2FWoltLab%2FWCF.git Changed API for action proxy's failure method --- diff --git a/wcfsetup/install/files/js/WCF.js b/wcfsetup/install/files/js/WCF.js index af4d4139c1..3b17ea4a19 100755 --- a/wcfsetup/install/files/js/WCF.js +++ b/wcfsetup/install/files/js/WCF.js @@ -1544,12 +1544,12 @@ WCF.Action.Proxy = Class.extend({ */ _failure: function(jqXHR, textStatus, errorThrown) { try { - var data = $.parseJSON(jqXHR.responseText); + var $data = $.parseJSON(jqXHR.responseText); // call child method if applicable var $showError = true; if ($.isFunction(this.options.failure)) { - $showError = this.options.failure(jqXHR, textStatus, errorThrown, jqXHR.responseText); + $showError = this.options.failure($data, jqXHR, textStatus, errorThrown); } if (!this._suppressErrors && $showError !== false) { @@ -1561,7 +1561,7 @@ WCF.Action.Proxy = Class.extend({ // call child method if applicable var $showError = true; if ($.isFunction(this.options.failure)) { - $showError = this.options.failure(jqXHR, textStatus, errorThrown, jqXHR.responseText); + $showError = this.options.failure(null, jqXHR, textStatus, errorThrown); } if (!this._suppressErrors && $showError !== false) {