Avoid NPE
parent
a654202e37
commit
34005e2a48
|
@ -208,8 +208,8 @@ const marketplaceWebExtensions = [
|
|||
'ms-vscode.references-view'
|
||||
];
|
||||
const productJson = JSON.parse(fs.readFileSync(path.join(__dirname, '../../product.json'), 'utf8'));
|
||||
const builtInExtensions = productJson.builtInExtensions;
|
||||
const webBuiltInExtensions = productJson.webBuiltInExtensions;
|
||||
const builtInExtensions = productJson.builtInExtensions || [];
|
||||
const webBuiltInExtensions = productJson.webBuiltInExtensions || [];
|
||||
/**
|
||||
* Loosely based on `getExtensionKind` from `src/vs/workbench/services/extensions/common/extensionsUtil.ts`
|
||||
*/
|
||||
|
|
|
@ -251,8 +251,8 @@ interface IBuiltInExtension {
|
|||
}
|
||||
|
||||
const productJson = JSON.parse(fs.readFileSync(path.join(__dirname, '../../product.json'), 'utf8'));
|
||||
const builtInExtensions: IBuiltInExtension[] = productJson.builtInExtensions;
|
||||
const webBuiltInExtensions: IBuiltInExtension[] = productJson.webBuiltInExtensions;
|
||||
const builtInExtensions: IBuiltInExtension[] = productJson.builtInExtensions || [];
|
||||
const webBuiltInExtensions: IBuiltInExtension[] = productJson.webBuiltInExtensions || [];
|
||||
|
||||
type ExtensionKind = 'ui' | 'workspace' | 'web';
|
||||
interface IExtensionManifest {
|
||||
|
|
Loading…
Reference in New Issue