mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-25 11:08:51 +01:00
Fix #79844
This commit is contained in:
@@ -34,22 +34,6 @@ export function getCustomDataPathsInAllWorkspaces(workspaceFolders: WorkspaceFol
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
if (
|
||||
wfHtmlConfig &&
|
||||
wfHtmlConfig.workspaceFolderValue &&
|
||||
wfHtmlConfig.workspaceFolderValue.experimental &&
|
||||
wfHtmlConfig.workspaceFolderValue.experimental.customData
|
||||
) {
|
||||
const customData = wfHtmlConfig.workspaceFolderValue.experimental.customData;
|
||||
if (Array.isArray(customData)) {
|
||||
customData.forEach(t => {
|
||||
if (typeof t === 'string') {
|
||||
dataPaths.push(path.resolve(wf.uri.fsPath, t));
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return dataPaths;
|
||||
@@ -61,30 +45,12 @@ export function getCustomDataPathsFromAllExtensions(): string[] {
|
||||
for (const extension of extensions.all) {
|
||||
const contributes = extension.packageJSON && extension.packageJSON.contributes;
|
||||
|
||||
if (
|
||||
contributes &&
|
||||
contributes.html &&
|
||||
contributes.html.customData &&
|
||||
Array.isArray(contributes.html.customData)
|
||||
) {
|
||||
if (contributes && contributes.html && contributes.html.customData && Array.isArray(contributes.html.customData)) {
|
||||
const relativePaths: string[] = contributes.html.customData;
|
||||
relativePaths.forEach(rp => {
|
||||
dataPaths.push(path.resolve(extension.extensionPath, rp));
|
||||
});
|
||||
}
|
||||
|
||||
if (
|
||||
contributes &&
|
||||
contributes.html &&
|
||||
contributes.html.experimental &&
|
||||
contributes.html.experimental.customData &&
|
||||
Array.isArray(contributes.html.experimental.customData)
|
||||
) {
|
||||
const relativePaths: string[] = contributes.html.experimental.customData;
|
||||
relativePaths.forEach(rp => {
|
||||
dataPaths.push(path.resolve(extension.extensionPath, rp));
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
return dataPaths;
|
||||
|
||||
Reference in New Issue
Block a user