git.asbjorn.biz
/
jquery.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Clearing event handlers on unload is no longer necessary in any version of IE. This...
[jquery.git]
/
src
/
ajax.js
diff --git
a/src/ajax.js
b/src/ajax.js
index
ceeef5e
..
3f4f732
100644
(file)
--- a/
src/ajax.js
+++ b/
src/ajax.js
@@
-343,7
+343,9
@@
function buildParams( prefix, obj, traditional, add ) {
});
} else if ( !traditional && obj != null && typeof obj === "object" ) {
});
} else if ( !traditional && obj != null && typeof obj === "object" ) {
- if ( jQuery.isEmptyObject( obj ) ) {
+ // If we see an array here, it is empty and should be treated as an empty
+ // object
+ if ( jQuery.isArray( obj ) || jQuery.isEmptyObject( obj ) ) {
add( prefix, "" );
// Serialize object item.
add( prefix, "" );
// Serialize object item.
@@
-401,4
+403,4
@@
jQuery.support.ajax = !!testXHR;
// Does this browser support crossDomain XHR requests
jQuery.support.cors = testXHR && "withCredentials" in testXHR;
// Does this browser support crossDomain XHR requests
jQuery.support.cors = testXHR && "withCredentials" in testXHR;
-})(jQuery);
\ No newline at end of file
+})( jQuery );