Calling load with null as the data parameter now properly issues a GET request, not a POST request. Unit tests added. Fixes #12234.

This commit is contained in:
jaubourg
2012-08-16 16:45:18 +02:00
parent aa1350d9e2
commit b292c4c2df
2 changed files with 36 additions and 2 deletions

View File

@@ -170,7 +170,7 @@ jQuery.fn.load = function( url, params, callback ) {
params = undefined;
// Otherwise, build a param string
} else if ( typeof params === "object" ) {
} else if ( params && typeof params === "object" ) {
type = "POST";
}