mirror of
https://github.com/jquery/jquery.git
synced 2026-01-24 07:18:07 -05:00
Fix fix for #6481 introduced at 7862c45ad2 which did not like it when Array.prototype was modified on empty arrays.
This commit is contained in:
@@ -343,7 +343,9 @@ function buildParams( prefix, obj, traditional, add ) {
|
||||
});
|
||||
|
||||
} 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.
|
||||
|
||||
Reference in New Issue
Block a user