We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2f48acd commit 5df32faCopy full SHA for 5df32fa
src/main/kotlin/org/domaframework/doma/intellij/formatter/processor/SqlFormatPreProcessor.kt
@@ -272,7 +272,9 @@ class SqlFormatPreProcessor : PreFormatProcessor {
272
prevElement: PsiElement?,
273
text: String,
274
): String =
275
- if (prevElement?.text?.contains(StringUtil.LINE_SEPARATE) == false) {
+ if (prevElement?.text?.contains(StringUtil.LINE_SEPARATE) == false &&
276
+ PsiTreeUtil.prevLeaf(prevElement) != null
277
+ ) {
278
"${StringUtil.LINE_SEPARATE}$text"
279
} else {
280
text
0 commit comments