Fixed "space-within-parens" lint rule

This commit is contained in:
Dmitri1337
2019-01-16 18:42:55 +02:00
parent 4af081994e
commit ced24f9e19
2 changed files with 6 additions and 7 deletions

View File

@@ -442,7 +442,7 @@ async.retry({ times: 3, interval: (retryCount) => 200 * retryCount }, function (
async.parallel([
function (callback: ( err: Error, val: string ) => void ) { },
function (callback: (err: Error, val: string) => void) { },
function (callback) { }
],
function (err: Error, results: string[]) {
@@ -738,7 +738,7 @@ async.some<number>({
// timeout
function myFunction1(foo: any, callback: (err?: Error, result?: any) => void ): void {
function myFunction1(foo: any, callback: (err?: Error, result?: any) => void): void {
console.log(`async.timeout 1 ${foo}`);
return callback(undefined, foo);
}
@@ -748,22 +748,22 @@ wrapped1({ bar: 'bar' }, function(err: Error, data: any) {
});
function myFunction2(callback: (err?: Error, result?: any) => void ): void {
function myFunction2(callback: (err?: Error, result?: any) => void): void {
console.log(`async.timeout 2`);
return callback(undefined, { bar: 'bar' });
}
var wrapped2 = async.timeout(myFunction2, 1000);
wrapped2( function(err: Error, data: any) {
wrapped2(function(err: Error, data: any) {
console.log(`async.timeout 2 end ${data}`);
});
function myFunction3(callback: (err?: Error, result?: any) => void ): void {
function myFunction3(callback: (err?: Error, result?: any) => void): void {
console.log(`async.timeout 3`);
return callback(undefined, { bar: 'bar' });
}
var wrapped3 = async.timeout(myFunction3, 1000, { bar: 'bar' });
wrapped3( function(err: Error, data: any) {
wrapped3(function(err: Error, data: any) {
console.log(`async.timeout 3 end ${data}`);
});

View File

@@ -19,7 +19,6 @@
"prefer-method-signature": false, // HAS ISSUES
"prefer-template": false, // HAS ISSUES
"space-before-function-paren": false, // HAS ISSUES
"space-within-parens": false, // HAS ISSUES
"unified-signatures": false // HAS ISSUES
}
}