提交 e18eda4d 编写于 作者: J Johannes Rieken

strict null trouble

上级 e63c7d08
......@@ -132,7 +132,7 @@ export const CommandsRegistry: ICommandRegistry = new class implements ICommandR
export const NullCommandService: ICommandService = {
_serviceBrand: undefined,
onWillExecuteCommand: () => ({ dispose: () => { } }),
executeCommand<T = any>() {
return Promise.resolve<T>(undefined);
executeCommand() {
return Promise.resolve(undefined);
}
};
......@@ -29,15 +29,15 @@ export class FileIconThemeData implements IFileIconTheme {
private constructor() { }
public ensureLoaded(fileService: IFileService): Promise<string> {
public ensureLoaded(fileService: IFileService): Promise<string | undefined> {
return !this.isLoaded ? this.load(fileService) : Promise.resolve(this.styleSheetContent);
}
public reload(fileService: IFileService): Promise<string> {
public reload(fileService: IFileService): Promise<string | undefined> {
return this.load(fileService);
}
private load(fileService: IFileService): Promise<string> {
private load(fileService: IFileService): Promise<string | undefined> {
if (!this.location) {
return Promise.resolve(this.styleSheetContent);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册