cleanup: remove unused variable assignment (#33917)

The initial value in `text` was being immediately overwritten by the next statement
This commit is contained in:
Ethan Resnick
2020-03-10 02:18:35 +04:30
committed by GitHub
parent bf15eac16e
commit 5d6b385e65

View File

@@ -21,9 +21,8 @@ class DeclarationsWalker {
static getExtraDeclarations(typeChecker: ts.TypeChecker, protocolFile: ts.SourceFile): string {
const walker = new DeclarationsWalker(typeChecker, protocolFile);
let text = "declare namespace ts.server.protocol {\n";
walker.visitTypeNodes(protocolFile);
text = walker.text
let text = walker.text
? `declare namespace ts.server.protocol {\n${walker.text}}`
: "";
if (walker.removedTypes) {