@@ -13,6 +13,7 @@ import { IEnvironmentService } from "vs/platform/environment/common/environment"
1313import { IExtensionDescription , ExtensionIdentifier } from "vs/platform/extensions/common/extensions" ;
1414import { FileDeleteOptions , FileOverwriteOptions , FileType , IStat , IWatchOptions , FileOpenOptions } from "vs/platform/files/common/files" ;
1515import { ILogService } from "vs/platform/log/common/log" ;
16+ import { IProductService } from "vs/platform/product/common/product" ;
1617import { IRemoteAgentEnvironment } from "vs/platform/remote/common/remoteAgentEnvironment" ;
1718import { ExtensionScanner , ExtensionScannerInput } from "vs/workbench/services/extensions/node/extensionPoints" ;
1819import { DiskFileSystemProvider } from "vs/workbench/services/files/node/diskFileSystemProvider" ;
@@ -199,14 +200,14 @@ export class ExtensionEnvironmentChannel implements IServerChannel {
199200
200201 private async scanExtensions ( locale : string ) : Promise < IExtensionDescription [ ] > {
201202 const root = getPathFromAmdModule ( require , "" ) ;
202- const pkg = require . __$__nodeRequire ( path . resolve ( root , "../package.json" ) ) as any ;
203+ const product = require . __$__nodeRequire ( path . resolve ( root , "../package.json" ) ) as IProductService ;
203204
204205 const translations = { } ; // TODO: translations
205206
206207 // TODO: there is also this.environment.extensionDevelopmentLocationURI to look into.
207208 const scanBuiltin = async ( ) : Promise < IExtensionDescription [ ] > => {
208209 const input = new ExtensionScannerInput (
209- pkg . version , pkg . commit , locale , ! ! process . env . VSCODE_DEV ,
210+ product . version , product . commit , locale , ! ! process . env . VSCODE_DEV ,
210211 path . resolve ( root , "../extensions" ) ,
211212 true ,
212213 false ,
@@ -219,7 +220,7 @@ export class ExtensionEnvironmentChannel implements IServerChannel {
219220
220221 const scanInstalled = async ( ) : Promise < IExtensionDescription [ ] > => {
221222 const input = new ExtensionScannerInput (
222- pkg . version , pkg . commit , locale , ! ! process . env . VSCODE_DEV ,
223+ product . version , product . commit , locale , ! ! process . env . VSCODE_DEV ,
223224 this . environment . extensionsPath , false , true , translations ,
224225 ) ;
225226 return ExtensionScanner . scanExtensions ( input , this . log ) ;
0 commit comments