"then" renamed "complete" and new "then" method defined using "complete" and "fail" internally. The API is still symetrical (complete/fail), still promotes AOP but is also now Promise/A compliant. Changed unit tests and ajax module accordingly.
This commit is contained in:
parent
4ab94a578e
commit
cbf591152c
3 changed files with 40 additions and 36 deletions
|
@ -496,9 +496,9 @@ jQuery.extend({
|
|||
|
||||
// Attach deferreds
|
||||
deferred.promise( jXHR );
|
||||
jXHR.success = jXHR.then;
|
||||
jXHR.success = jXHR.complete;
|
||||
jXHR.error = jXHR.fail;
|
||||
jXHR.complete = completeDeferred.then;
|
||||
jXHR.complete = completeDeferred.complete;
|
||||
|
||||
// Remove hash character (#7531: and string promotion)
|
||||
s.url = ( "" + s.url ).replace( rhash , "" );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue