From bac456cbbb84772bb18e3000629214cc97def177 Mon Sep 17 00:00:00 2001 From: Dustin Campbell Date: Fri, 26 Aug 2016 10:45:35 -0700 Subject: [PATCH] Tweak indent string generation slightly to make greggm smile --- src/omnisharp/logger.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/omnisharp/logger.ts b/src/omnisharp/logger.ts index 6f38da3..ccb89d4 100644 --- a/src/omnisharp/logger.ts +++ b/src/omnisharp/logger.ts @@ -9,8 +9,8 @@ export class Logger { private _writer: (message: string) => void; private _prefix: string; - private _indent: string = ' '; private _indentLevel: number = 0; + private _indentSize: number = 4; private _atLineStart: boolean = false; constructor(writer: (message: string) => void, prefix?: string) { @@ -21,8 +21,7 @@ export class Logger { private _appendCore(message: string): void { if (this._atLineStart) { if (this._indentLevel > 0) { - const repeatCount = this._indentLevel; - const indent = this._indent.repeat(repeatCount); + const indent = " ".repeat(this._indentLevel * this._indentSize); this._writer(indent); }