bad types?

This commit is contained in:
Joao Moreno 2017-07-06 08:57:33 +02:00
parent 6d3a1e43d7
commit 81026f6952
2 changed files with 3 additions and 3 deletions

View file

@ -20,7 +20,7 @@ function exec(command: string, options: IOptions = {}, cancellationToken?: Cance
return new Promise((c, e) => {
let disposeCancellationListener: Function = null;
const child = cp.exec(command, { ...options, encoding: 'utf8' }, (err, stdout: string, stderr: string) => {
const child = cp.exec(command, { ...options, encoding: 'utf8' } as any, (err, stdout: string, stderr: string) => {
if (disposeCancellationListener) {
disposeCancellationListener();
disposeCancellationListener = null;

View file

@ -23,8 +23,8 @@ interface IReadFile {
}
const readFile = denodeify<string, string, string>(fs.readFile);
const writeFile = denodeify<string, string, string, void>(fs.writeFile);
const unlink = denodeify<string, void>(fs.unlink);
const writeFile = denodeify<string, string, string, void>(fs.writeFile as any);
const unlink = denodeify<string, void>(fs.unlink as any);
const exec = denodeify<string, { cwd?: string; env?: any; }, { stdout: string; stderr: string; }>(cp.exec, (err, stdout, stderr) => [err, { stdout, stderr }]);
const glob = denodeify<string, _glob.Options, string[]>(_glob);