From d4a4ae01b2f7ad7fdd7aa530b1bfdb029481feb7 Mon Sep 17 00:00:00 2001 From: Ali Ariff Date: Sat, 31 Aug 2024 14:00:36 +0200 Subject: [PATCH] refactor: Update HtmlBeautifier class to handle error cases and improve code readability --- src/formatter/htmlbeautifier.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/formatter/htmlbeautifier.ts b/src/formatter/htmlbeautifier.ts index 37eddab..33acd52 100644 --- a/src/formatter/htmlbeautifier.ts +++ b/src/formatter/htmlbeautifier.ts @@ -233,7 +233,7 @@ export default class HtmlBeautifier { const eol = vscode.workspace.getConfiguration().get("files.eol"); // Determine newline character(s) based on the 'files.eol' setting and the platform - let newline = eol === "auto" ? (this.isWindows() ? "\r\n" : "\n") : eol; + const newline = eol === "auto" ? (this.isWindows() ? "\r\n" : "\n") : eol; // Append the newline to the result result += newline;