From: John Resig Date: Tue, 9 Nov 2010 17:40:55 +0000 (-0500) Subject: Merge branch 'bug7422' of https://github.com/csnover/jquery into csnover-bug7422 X-Git-Url: http://git.asbjorn.biz/?p=jquery.git;a=commitdiff_plain;h=aa743969763bde258fd16979c7205605ac6eae0f;hp=-c Merge branch 'bug7422' of https://github.com/csnover/jquery into csnover-bug7422 --- aa743969763bde258fd16979c7205605ac6eae0f diff --combined src/ajax.js index 9195bcc,690bcb5..d10b931 --- a/src/ajax.js +++ b/src/ajax.js @@@ -463,10 -463,11 +463,11 @@@ jQuery.extend( try { var oldAbort = xhr.abort; xhr.abort = function() { - // xhr.abort in IE7 is not a native JS function - // and does not have a call property - if ( xhr && oldAbort.call ) { - oldAbort.call( xhr ); + if ( xhr ) { + // oldAbort has no call property in IE7 so + // just do it this way, which works in all + // browsers + Function.prototype.call.call( oldAbort, xhr ); } onreadystatechange( "abort" ); @@@ -506,12 -507,11 +507,12 @@@ // Serialize an array of form elements or a set of // key/values into a query string param: function( a, traditional ) { - var s = [], add = function( key, value ) { - // If value is a function, invoke it and return its value - value = jQuery.isFunction(value) ? value() : value; - s[ s.length ] = encodeURIComponent(key) + "=" + encodeURIComponent(value); - }; + var s = [], + add = function( key, value ) { + // If value is a function, invoke it and return its value + value = jQuery.isFunction(value) ? value() : value; + s[ s.length ] = encodeURIComponent(key) + "=" + encodeURIComponent(value); + }; // Set traditional to true for jQuery <= 1.3.2 behavior. if ( traditional === undefined ) {