git.asbjorn.biz
/
jquery.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove an unused regex and optimize character escape regex usage.
[jquery.git]
/
src
/
ajax
/
script.js
diff --git
a/src/ajax/script.js
b/src/ajax/script.js
index
645ddf3
..
b0e576f
100644
(file)
--- a/
src/ajax/script.js
+++ b/
src/ajax/script.js
@@
-14,20
+14,24
@@
jQuery.ajaxSetup({
converters: {
"text script": jQuery.globalEval
}
converters: {
"text script": jQuery.globalEval
}
-});
-// Bind script tag hack transport
-jQuery.ajax.transport("script", function(s) {
+// Handle cache's special case and global
+}).ajaxPrefilter("script", function(s) {
- // Handle cache special case
if ( s.cache === undefined ) {
s.cache = false;
}
if ( s.cache === undefined ) {
s.cache = false;
}
- // This transport only deals with cross domain get requests
- if ( s.crossDomain && s.async && ( s.type === "GET" || ! s.data ) ) {
-
+ if ( s.crossDomain ) {
+ s.type = "GET";
s.global = false;
s.global = false;
+ }
+
+// Bind script tag hack transport
+}).ajaxTransport("script", function(s) {
+
+ // This transport only deals with cross domain requests
+ if ( s.crossDomain ) {
var script,
head = document.getElementsByTagName("head")[0] || document.documentElement;
var script,
head = document.getElementsByTagName("head")[0] || document.documentElement;