diff options
author | Dave Methvin <dave.methvin@gmail.com> | 2017-09-12 11:24:45 -0400 |
---|---|---|
committer | Dave Methvin <dave.methvin@gmail.com> | 2018-01-15 21:48:54 -0500 |
commit | d7237896c79a5a10d85fcdec199c5657a469a92b (patch) | |
tree | c6e5900dbf4b91e0aad67af655ba4e52c3034e98 /src/ajax.js | |
parent | 022b69a44e42684bdd0029dd456bedb3b495cc24 (diff) | |
download | jquery-d7237896c79a5a10d85fcdec199c5657a469a92b.tar.gz jquery-d7237896c79a5a10d85fcdec199c5657a469a92b.zip |
Ajax: Don't process non-string data property on no-entity-body requests
Fixes gh-3438
Closes gh-3781
Diffstat (limited to 'src/ajax.js')
-rw-r--r-- | src/ajax.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ajax.js b/src/ajax.js index dd1321240..aec26830a 100644 --- a/src/ajax.js +++ b/src/ajax.js @@ -597,8 +597,8 @@ jQuery.extend( { // Remember the hash so we can put it back uncached = s.url.slice( cacheURL.length ); - // If data is available, append data to url - if ( s.data ) { + // If data is available and should be processed, append data to url + if ( s.data && ( s.processData || typeof s.data === "string" ) ) { cacheURL += ( rquery.test( cacheURL ) ? "&" : "?" ) + s.data; // #9682: remove data so that it's not used in an eventual retry |