aboutsummaryrefslogtreecommitdiffstats
path: root/bower_components/jquery/src/ajax.js
diff options
context:
space:
mode:
Diffstat (limited to 'bower_components/jquery/src/ajax.js')
-rw-r--r--bower_components/jquery/src/ajax.js10
1 files changed, 2 insertions, 8 deletions
diff --git a/bower_components/jquery/src/ajax.js b/bower_components/jquery/src/ajax.js
index 1b01fd6..8a1b8b6 100644
--- a/bower_components/jquery/src/ajax.js
+++ b/bower_components/jquery/src/ajax.js
@@ -537,7 +537,8 @@ jQuery.extend({
}
// We can fire global events as of now if asked to
- fireGlobals = s.global;
+ // Don't fire events if jQuery.event is undefined in an AMD-usage scenario (#15118)
+ fireGlobals = jQuery.event && s.global;
// Watch for a new set of requests
if ( fireGlobals && jQuery.active++ === 0 ) {
@@ -796,12 +797,5 @@ jQuery.each( [ "get", "post" ], function( i, method ) {
};
});
-// Attach a bunch of functions for handling common AJAX events
-jQuery.each( [ "ajaxStart", "ajaxStop", "ajaxComplete", "ajaxError", "ajaxSuccess", "ajaxSend" ], function( i, type ) {
- jQuery.fn[ type ] = function( fn ) {
- return this.on( type, fn );
- };
-});
-
return jQuery;
});