Skip to content

Commit

Permalink
Correctly handle line breaks in QueryRenderer
Browse files Browse the repository at this point in the history
  • Loading branch information
Armin Wiebigke committed Aug 22, 2024
1 parent 42eec4c commit 172c343
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,7 @@ object QueryRenderer {
extraIndent: Boolean = true): String =
if (node.value.trim.nonEmpty) {
val ind = if (extraIndent) indent.incForce.str else indent.strForce
val lines = escapeBlockString(node.value).split("\n").iterator.map { line =>
val lines = escapeBlockString(node.value).linesIterator.iterator.map { line =>
if (line.isEmpty) line // do not output lines with only whitespaces inside
else ind + line
}
Expand Down

0 comments on commit 172c343

Please sign in to comment.