Fix printer leftover check

This commit is contained in:
Jake Bailey
2025-10-24 14:16:33 -07:00
parent 8b18abb79e
commit 5a7ff13dd8
+1 -1
View File
@@ -2608,7 +2608,7 @@ export function createPrinter(printerOptions: PrinterOptions = {}, handlers: Pri
}
const preferNewLine = node.multiLine ? ListFormat.PreferNewLine : ListFormat.None;
const allowTrailingComma = currentSourceFile && currentSourceFile.languageVersion >= ScriptTarget.ES5 && !isJsonSourceFile(currentSourceFile) ? ListFormat.AllowTrailingComma : ListFormat.None;
const allowTrailingComma = currentSourceFile && !isJsonSourceFile(currentSourceFile) ? ListFormat.AllowTrailingComma : ListFormat.None;
emitList(node, node.properties, ListFormat.ObjectLiteralExpressionProperties | allowTrailingComma | preferNewLine);
if (indentedFlag) {