code: function instantDeferred(resolve, returnValue, context) {
  	var deferred = $.Deferred();
  	if (resolve) {
  		deferred.resolveWith(context, [returnValue]);
  	} else {
  		deferred.rejectWith(context, [returnValue]);
  	}
  
  	return deferred;
  }
docs: factory method to create a $.Deferred that is already completed