diff --git a/extensions/typescript-basics/build/update-grammars.mjs b/extensions/typescript-basics/build/update-grammars.mjs index 82f6ab3107a..175f83f0ba3 100644 --- a/extensions/typescript-basics/build/update-grammars.mjs +++ b/extensions/typescript-basics/build/update-grammars.mjs @@ -50,7 +50,7 @@ function removeNodeTypes(grammar) { function patchJsdoctype(grammar) { grammar.repository['jsdoctype'].patterns = grammar.repository['jsdoctype'].patterns.filter(pattern => { - if (pattern.name && pattern.name.indexOf('illegal') >= -1) { + if (pattern.name && pattern.name.includes('illegal')) { return false; } return true;