From 2118de09e7195874c25af3f93aade124f3a5aa8a Mon Sep 17 00:00:00 2001 From: Arthur Ozga Date: Mon, 1 May 2017 15:16:42 -0700 Subject: [PATCH] Simplify returns --- src/compiler/program.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/compiler/program.ts b/src/compiler/program.ts index 4ef1d7939c6..97f09c083f5 100644 --- a/src/compiler/program.ts +++ b/src/compiler/program.ts @@ -643,13 +643,11 @@ namespace ts { // there is an old program, check if we can reuse its structure const oldRootNames = oldProgram.getRootFileNames(); if (!arrayIsEqualTo(oldRootNames, rootNames)) { - oldProgram.structureIsReused = StructureIsReused.Not; - return StructureIsReused.Not; + return oldProgram.structureIsReused = StructureIsReused.Not; } if (!arrayIsEqualTo(options.types, oldOptions.types)) { - oldProgram.structureIsReused = StructureIsReused.Not; - return StructureIsReused.Not; + return oldProgram.structureIsReused = StructureIsReused.Not; } // check if program source files has changed in the way that can affect structure of the program