arduino-ide/arduino-ide-extension/src/browser/workspace-service-ext-impl.ts
Akos Kitta 7c3d830ea2 Reverted an obsolete change.
Signed-off-by: Akos Kitta <kittaakos@typefox.io>
2019-05-08 22:31:09 +02:00

19 lines
615 B
TypeScript

import { inject, injectable } from 'inversify';
import { WorkspaceService } from '@theia/workspace/lib/browser/workspace-service';
import { WorkspaceServiceExt } from './workspace-service-ext';
/**
* This is a workaround to be able to inject the workspace service to the backend with its service path.
*/
@injectable()
export class WorkspaceServiceExtImpl implements WorkspaceServiceExt {
@inject(WorkspaceService)
protected readonly delegate: WorkspaceService;
async roots(): Promise<string[]> {
const stats = await this.delegate.roots;
return stats.map(stat => stat.uri);
}
}