mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-27 03:54:24 +01:00
debt - replace winjs.promise#join with promise#all
This commit is contained in:
@@ -7,7 +7,6 @@
|
||||
import { basename, dirname, join } from 'path';
|
||||
import { onUnexpectedError } from 'vs/base/common/errors';
|
||||
import { dispose, IDisposable } from 'vs/base/common/lifecycle';
|
||||
import { TPromise } from 'vs/base/common/winjs.base';
|
||||
import { readdir, rimraf, stat } from 'vs/base/node/pfs';
|
||||
import { IEnvironmentService } from 'vs/platform/environment/common/environment';
|
||||
import product from 'vs/platform/node/product';
|
||||
@@ -49,7 +48,7 @@ export class NodeCachedDataCleaner {
|
||||
readdir(nodeCachedDataRootDir).then(entries => {
|
||||
|
||||
const now = Date.now();
|
||||
const deletes: TPromise<any>[] = [];
|
||||
const deletes: Thenable<any>[] = [];
|
||||
|
||||
entries.forEach(entry => {
|
||||
// name check
|
||||
@@ -72,7 +71,7 @@ export class NodeCachedDataCleaner {
|
||||
}
|
||||
});
|
||||
|
||||
return TPromise.join(deletes);
|
||||
return Promise.all(deletes);
|
||||
|
||||
}).then(undefined, onUnexpectedError);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user