function createOverride(sXHRMethod) {

		mRegistry[sXHRMethod] = Object.create(null);

		//  backup the original function
		mXHRFunctions[sXHRMethod] = window.XMLHttpRequest.prototype[sXHRMethod];

		window.XMLHttpRequest.prototype[sXHRMethod] = function() {
			var oArgs = arguments;

			// call the original function first
			mXHRFunctions[sXHRMethod].apply(this, oArgs);

			// call the registered callbacks in order of their registration
			for (var sName in mRegistry[sXHRMethod]) {
				mRegistry[sXHRMethod][sName].apply(this, oArgs);
			}

		};

	}
function createOverride(sXHRMethod) {

		mRegistry[sXHRMethod] = Object.create(null);

		//  backup the original function
		mXHRFunctions[sXHRMethod] = window.XMLHttpRequest.prototype[sXHRMethod];

		window.XMLHttpRequest.prototype[sXHRMethod] = function() {
			var oArgs = arguments;

			// call the original function first
			mXHRFunctions[sXHRMethod].apply(this, oArgs);

			// call the registered callbacks in order of their registration
			for (var sName in mRegistry[sXHRMethod]) {
				mRegistry[sXHRMethod][sName].apply(this, oArgs);
			}

		};

	}
function createOverride ( sXHRMethod ) { mRegistry [ sXHRMethod ] = Object . create ( null ) ; //  backup the original function mXHRFunctions [ sXHRMethod ] = window . XMLHttpRequest . prototype [ sXHRMethod ] ; window . XMLHttpRequest . prototype [ sXHRMethod ] = function ( ) { var oArgs = arguments ; // call the original function first mXHRFunctions [ sXHRMethod ] . apply ( this , oArgs ) ; // call the registered callbacks in order of their registration for ( var sName in mRegistry [ sXHRMethod ] ) { mRegistry [ sXHRMethod ] [ sName ] . apply ( this , oArgs ) ; } } ; }
Creates the initial override for an original XHR method.

@param {string} sXHRMethod Name of the actual XHR method
@param {function} fnCallback The registered callback function
@private
Creates the initial override for an original XHR method .
Creates a function that will be called when an XHR method is called.