Remove any cast

This commit is contained in:
Alex Dima 2018-08-08 15:46:01 +02:00
parent 1e6ff8e032
commit a56039de2d

View file

@ -126,8 +126,7 @@ export class TypeScriptWorker implements ts.LanguageServiceHost {
// contains cyclic data structures. // contains cyclic data structures.
diagnostics.forEach(diag => { diagnostics.forEach(diag => {
diag.file = undefined; diag.file = undefined;
// FIXME: What is the procedure to upgrade the TypeScript typings? const related = <ts.Diagnostic[]>diag.relatedInformation;
const related = <ts.Diagnostic[]>(<any>diag).relatedInformation;
if (related) { if (related) {
related.forEach(diag2 => diag2.file = undefined); related.forEach(diag2 => diag2.file = undefined);
} }