chore(vscode): update to 1.55.2

This commit is contained in:
Akash Satheesan
2021-04-09 11:32:27 +05:30
1102 changed files with 39988 additions and 23544 deletions

View File

@@ -237,14 +237,14 @@ XLF.parse = function (xlfString) {
}
let val = unit.target[0];
if (typeof val !== 'string') {
val = val._;
// We allow empty source values so support them for translations as well.
val = val._ ? val._ : '';
}
if (key && val) {
messages[key] = decodeEntities(val);
}
else {
reject(new Error(`XLF parsing error: XLIFF file ${originalFilePath} does not contain full localization data. ID or target translation for one of the trans-unit nodes is not present.`));
if (!key) {
reject(new Error(`XLF parsing error: trans-unit ${JSON.stringify(unit, undefined, 0)} defined in file ${originalFilePath} is missing the ID attribute.`));
return;
}
messages[key] = decodeEntities(val);
});
files.push({ messages: messages, originalFilePath: originalFilePath, language: language.toLowerCase() });
}