diff --git a/module/module-database-core/src/main/kotlin/taboolib/module/database/ResultProcessorList.kt b/module/module-database-core/src/main/kotlin/taboolib/module/database/ResultProcessorList.kt index 1696edd45..3d8f83fb2 100644 --- a/module/module-database-core/src/main/kotlin/taboolib/module/database/ResultProcessorList.kt +++ b/module/module-database-core/src/main/kotlin/taboolib/module/database/ResultProcessorList.kt @@ -10,7 +10,7 @@ import java.sql.ResultSet */ open class ResultProcessorList(processors: List, val source: ExecutableSource? = null) { - val processors = processors.toMutableList() + private val processors = processors.toMutableList() /** 是否已经执行 */ var isExecuted = false diff --git a/module/module-database-core/src/main/kotlin/taboolib/module/database/Table.kt b/module/module-database-core/src/main/kotlin/taboolib/module/database/Table.kt index 6f6338ca2..1dc108b1b 100644 --- a/module/module-database-core/src/main/kotlin/taboolib/module/database/Table.kt +++ b/module/module-database-core/src/main/kotlin/taboolib/module/database/Table.kt @@ -32,8 +32,8 @@ open class Table, E : ColumnBuilder>(val name: String, val host: Hos workspace(dataSource) { createTable(checkExists) }.run() } - open fun select(dataSource: DataSource, func: ActionSelect.() -> Unit): ResultProcessor { - return workspace(dataSource) { select(func) }.processors.first() + open fun select(dataSource: DataSource, func: ActionSelect.() -> Unit): ResultProcessorList { + return workspace(dataSource) { select(func) } } open fun find(dataSource: DataSource, func: ActionSelect.() -> Unit): Boolean {