Skip to content

Commit

Permalink
fix code style
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentlauvlwj committed Jul 16, 2023
1 parent a783546 commit efd6711
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -76,17 +76,16 @@ internal object AddFunctionGenerator {

internal fun checkForDml(): CodeBlock {
val code = """
val isModified =
expression.where != null ||
expression.groupBy.isNotEmpty() ||
expression.having != null ||
expression.isDistinct ||
expression.orderBy.isNotEmpty() ||
expression.offset != null ||
expression.limit != null
val isModified = expression.where != null
|| expression.groupBy.isNotEmpty()
|| expression.having != null
|| expression.isDistinct
|| expression.orderBy.isNotEmpty()
|| expression.offset != null
|| expression.limit != null
if (isModified) {
val msg =
val msg = "" +
"Entity manipulation functions are not supported by this sequence object. " +
"Please call on the origin sequence returned from database.sequenceOf(table)"
throw UnsupportedOperationException(msg)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ internal object RefsClassGenerator {
val refTableClass = ClassName(refTable.entityClass.packageName.asString(), refTable.tableClassName)

val propertySpec = PropertySpec.builder(column.refTablePropertyName!!, refTableClass)
.addKdoc("Return the referenced table [${refTable.tableClassName}].")
.addKdoc("Return the referenced table of [${table.tableClassName}.${column.columnPropertyName}].")
.initializer(CodeBlock.of("t.%N.referenceTable as %T", column.columnPropertyName, refTableClass))
.build()

Expand Down

0 comments on commit efd6711

Please sign in to comment.