提交 4c2913d8 编写于 作者: S Sandeep Somavarapu

ExtensionsActions - Strict null check

上级 4ebe0f0c
......@@ -726,7 +726,7 @@ export class ExtensionsWorkbenchService implements IExtensionsWorkbenchService,
}
if (!extension.gallery) {
return Promise.resolve();
return Promise.reject(new Error('Missing gallery'));
}
return this.galleryService.getExtension(extension.gallery.identifier, version)
......@@ -736,7 +736,11 @@ export class ExtensionsWorkbenchService implements IExtensionsWorkbenchService,
}
return this.installWithProgress(
() => this.extensionService.installFromGallery(gallery)
.then(() => this.ignoreAutoUpdate(gallery.identifier.id, version))
.then(() => {
if (extension.latestVersion !== version) {
this.ignoreAutoUpdate(gallery.identifier.id, version);
}
})
, gallery.displayName);
});
}
......@@ -919,8 +923,6 @@ export class ExtensionsWorkbenchService implements IExtensionsWorkbenchService,
extension = new Extension(this.galleryService, this.stateProvider, [], gallery, this.telemetryService, this.logService);
}
extension.gallery = gallery;
this.installing.push(extension);
this._onChange.fire(extension);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册