mirror of
https://github.com/jquery/jquery.git
synced 2026-02-01 11:35:18 -05:00
Ajax: improve content-type detection
Fixes gh-2584 Closes gh-2643
This commit is contained in:
@@ -322,9 +322,9 @@ jQuery.extend( {
|
||||
},
|
||||
|
||||
contents: {
|
||||
xml: /xml/,
|
||||
html: /html/,
|
||||
json: /json/
|
||||
xml: /\bxml\b/,
|
||||
html: /\bhtml/,
|
||||
json: /\bjson\b/
|
||||
},
|
||||
|
||||
responseFields: {
|
||||
|
||||
@@ -18,7 +18,7 @@ jQuery.ajaxSetup( {
|
||||
"application/ecmascript, application/x-ecmascript"
|
||||
},
|
||||
contents: {
|
||||
script: /(?:java|ecma)script/
|
||||
script: /\b(?:java|ecma)script\b/
|
||||
},
|
||||
converters: {
|
||||
"text script": function( text ) {
|
||||
|
||||
Reference in New Issue
Block a user