File tree Expand file tree Collapse file tree 1 file changed +7
-11
lines changed
src/main/kotlin/org/domaframework/doma/intellij/formatter/util Expand file tree Collapse file tree 1 file changed +7
-11
lines changed Original file line number Diff line number Diff line change @@ -126,20 +126,16 @@ class SqlBlockUtil(
126126
127127 IndentType .CONFLICT -> {
128128 if (lastGroupBlock is SqlConflictClauseBlock ) {
129- when (keywordText) {
130- " conflict" -> {
131- lastGroupBlock.conflictType = OnConflictKeywordType .CONFLICT
129+ lastGroupBlock.conflictType =
130+ when (keywordText) {
131+ " conflict" -> OnConflictKeywordType .CONFLICT
132+ " constraint" -> OnConflictKeywordType .CONSTRAINT
133+ else -> OnConflictKeywordType .UNKNOWN
132134 }
133- " constraint" -> {
134- lastGroupBlock.conflictType = OnConflictKeywordType .CONSTRAINT
135- }
136- else -> {
137- lastGroupBlock.conflictType = OnConflictKeywordType .UNKNOWN
138- }
139- }
140135 return SqlKeywordBlock (child, indentLevel, sqlBlockFormattingCtx)
136+ } else {
137+ return SqlConflictClauseBlock (child, sqlBlockFormattingCtx)
141138 }
142- return SqlConflictClauseBlock (child, sqlBlockFormattingCtx)
143139 }
144140
145141 else -> return SqlKeywordBlock (child, indentLevel, sqlBlockFormattingCtx)
You can’t perform that action at this time.
0 commit comments