Commit 05337e78 authored by Dave Methvin's avatar Dave Methvin

Revert "Fix #11586. Ajax DELETE ain't got no body, so data goes to its URL."

This reverts commit c01e022f.

We actually changed DELETE to accept a body on purpose, see http://bugs.jquery.com/ticket/7285 .
parent a5be9862
...@@ -7,7 +7,7 @@ var // Document location ...@@ -7,7 +7,7 @@ var // Document location
rheaders = /^(.*?):[ \t]*([^\r\n]*)\r?$/mg, // IE leaves an \r character at EOL rheaders = /^(.*?):[ \t]*([^\r\n]*)\r?$/mg, // IE leaves an \r character at EOL
// #7653, #8125, #8152: local protocol detection // #7653, #8125, #8152: local protocol detection
rlocalProtocol = /^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/, rlocalProtocol = /^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,
rnoContent = /^(?:GET|HEAD|DELETE)$/, rnoContent = /^(?:GET|HEAD)$/,
rprotocol = /^\/\//, rprotocol = /^\/\//,
rquery = /\?/, rquery = /\?/,
rscript = /<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi, rscript = /<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,
......
...@@ -840,21 +840,6 @@ test("jQuery.ajax - HEAD requests", function() { ...@@ -840,21 +840,6 @@ test("jQuery.ajax - HEAD requests", function() {
}); });
test("jQuery.ajax - DELETE requests", function() {
expect(1);
jQuery.ajax({
url: "devo.html",
type: "DELETE",
data: { "whip": "it", "qty": "good" },
beforeSend: function( _ , s ) {
equal( s.url, "devo.html?whip=it&qty=good", "Delete requests encode data in URL" );
return false;
}
});
});
test("jQuery.ajax - beforeSend", function() { test("jQuery.ajax - beforeSend", function() {
expect(1); expect(1);
stop(); stop();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment