From 19d5e3f7163bcfe9f6493619e50446336c5dfdb9 Mon Sep 17 00:00:00 2001 From: Chantal Loncle <82039410+bog-walk@users.noreply.github.com> Date: Thu, 15 Aug 2024 21:25:38 -0400 Subject: [PATCH] feat!: EXPOSED-320 Many-to-many relation with extra columns - Fix detekt issue --- .../main/kotlin/org/jetbrains/exposed/dao/InnerTableLink.kt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/exposed-dao/src/main/kotlin/org/jetbrains/exposed/dao/InnerTableLink.kt b/exposed-dao/src/main/kotlin/org/jetbrains/exposed/dao/InnerTableLink.kt index 2d81bd470d..76aa8a4d93 100644 --- a/exposed-dao/src/main/kotlin/org/jetbrains/exposed/dao/InnerTableLink.kt +++ b/exposed-dao/src/main/kotlin/org/jetbrains/exposed/dao/InnerTableLink.kt @@ -78,8 +78,7 @@ class InnerTableLink, Source : Entity, ID : Comparabl columns to entityTables } - private val additionalColumns = (additionalColumns - ?: (table.columns - sourceColumn - targetColumn).filter { !it.columnType.isAutoInc }) + private val additionalColumns = (additionalColumns ?: (table.columns - sourceColumn - targetColumn).filter { !it.columnType.isAutoInc }) .takeIf { it.isEmpty() || target is InnerTableLinkEntityClass } ?: error("Target entity must extend InnerTableLinkEntity to properly store and cache additional column data")