From badcd1b6f301e6253405f17759c1270549a34e12 Mon Sep 17 00:00:00 2001 From: Michał Gołębiowski Date: Mon, 2 Sep 2013 19:21:09 +0200 Subject: Fix #10814. Fix #14084. Make support tests lazy and broken out to components. --- src/ajax/xhr.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/ajax') diff --git a/src/ajax/xhr.js b/src/ajax/xhr.js index ab5bd5e1e..0217ce0f4 100644 --- a/src/ajax/xhr.js +++ b/src/ajax/xhr.js @@ -1,8 +1,8 @@ define([ "../core", - "../ajax", - "../support" -], function( jQuery ) { + "../var/support", + "../ajax" +], function( jQuery, support ) { var xhrCallbacks, xhrSupported, xhrId = 0, @@ -45,15 +45,15 @@ jQuery.ajaxSettings.xhr = window.ActiveXObject ? // Determine support properties xhrSupported = jQuery.ajaxSettings.xhr(); -jQuery.support.cors = !!xhrSupported && ( "withCredentials" in xhrSupported ); -xhrSupported = jQuery.support.ajax = !!xhrSupported; +support.cors = !!xhrSupported && ( "withCredentials" in xhrSupported ); +xhrSupported = support.ajax = !!xhrSupported; // Create transport if the browser can provide an xhr if ( xhrSupported ) { jQuery.ajaxTransport(function( s ) { // Cross domain only allowed if supported through XMLHttpRequest - if ( !s.crossDomain || jQuery.support.cors ) { + if ( !s.crossDomain || support.cors ) { var callback; -- cgit v1.2.3