From 6ad58b242e2fe4d8d0adb9009c6f0e7e59d56253 Mon Sep 17 00:00:00 2001 From: Wesley Wigham Date: Wed, 7 Nov 2018 15:46:13 -0800 Subject: [PATCH] Do not output summary if theres nothing to report --- src/compiler/watch.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/compiler/watch.ts b/src/compiler/watch.ts index 345991baef..24563c1b53 100644 --- a/src/compiler/watch.ts +++ b/src/compiler/watch.ts @@ -117,6 +117,7 @@ namespace ts { } export function getErrorSummaryText(errorCount: number, newLine: string) { + if (errorCount === 0) return ""; const d = createCompilerDiagnostic(errorCount === 1 ? Diagnostics.Found_1_error : Diagnostics.Found_0_errors, errorCount); return `${newLine}${flattenDiagnosticMessageText(d.messageText, newLine)}${newLine}${newLine}`; }