Archived
1
0

Add /vscode to nls fetch

A plugin may modify the root endpoint which will make /resource no
longer work so always use /vscode/resource instead.
This commit is contained in:
Asher 2020-09-09 12:05:44 -05:00
parent 938b460685
commit ffe6a663aa
No known key found for this signature in database
GPG Key ID: D63C1EF81242354A

View File

@ -17,7 +17,7 @@ try {
} }
// FIXME: Only works if path separators are /. // FIXME: Only works if path separators are /.
const path = nlsConfig._resolvedLanguagePackCoreLocation + "/" + bundle.replace(/\//g, "!") + ".nls.json" const path = nlsConfig._resolvedLanguagePackCoreLocation + "/" + bundle.replace(/\//g, "!") + ".nls.json"
fetch(`${options.base}/resource/?path=${encodeURIComponent(path)}`) fetch(`${options.base}/vscode/resource/?path=${encodeURIComponent(path)}`)
.then((response) => response.json()) .then((response) => response.json())
.then((json) => { .then((json) => {
bundles[bundle] = json bundles[bundle] = json