Build: update grunt-jscs-checker and pass with the new rules

This commit is contained in:
Timmy Willison
2014-07-17 10:25:59 -07:00
parent 8e3a0ceafa
commit c869a1ef8a
39 changed files with 352 additions and 187 deletions

View File

@@ -24,7 +24,9 @@ jQuery.ajaxPrefilter( "json jsonp", function( s, originalSettings, jqXHR ) {
var callbackName, overwritten, responseContainer,
jsonProp = s.jsonp !== false && ( rjsonp.test( s.url ) ?
"url" :
typeof s.data === "string" && !( s.contentType || "" ).indexOf("application/x-www-form-urlencoded") && rjsonp.test( s.data ) && "data"
typeof s.data === "string" &&
!( s.contentType || "" ).indexOf("application/x-www-form-urlencoded") &&
rjsonp.test( s.data ) && "data"
);
// Handle iff the expected data type is "jsonp" or we have a parameter to set

View File

@@ -6,7 +6,8 @@ define([
// Install script dataType
jQuery.ajaxSetup({
accepts: {
script: "text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"
script: "text/javascript, application/javascript, " +
"application/ecmascript, application/x-ecmascript"
},
contents: {
script: /(?:java|ecma)script/

View File

@@ -7,7 +7,7 @@ define([
jQuery.ajaxSettings.xhr = function() {
try {
return new XMLHttpRequest();
} catch( e ) {}
} catch ( e ) {}
};
var xhrId = 0,
@@ -45,7 +45,13 @@ jQuery.ajaxTransport(function( options ) {
xhr = options.xhr(),
id = ++xhrId;
xhr.open( options.type, options.url, options.async, options.username, options.password );
xhr.open(
options.type,
options.url,
options.async,
options.username,
options.password
);
// Apply custom fields if provided
if ( options.xhrFields ) {