mirror of
https://github.com/gotson/komga.git
synced 2026-05-01 11:25:24 +02:00
refactor: remove unnecessary apply
This commit is contained in:
parent
7cc60788b1
commit
c4a439276a
1 changed files with 8 additions and 10 deletions
|
|
@ -15,14 +15,12 @@ class DataSourcesConfiguration(
|
|||
|
||||
@Bean("sqliteDataSource")
|
||||
@Primary
|
||||
fun sqliteDataSource(): DataSource =
|
||||
(
|
||||
DataSourceBuilder.create()
|
||||
.apply {
|
||||
driverClassName("org.sqlite.JDBC")
|
||||
url("jdbc:sqlite:${komgaProperties.database.file}?foreign_keys=on;")
|
||||
}.type(HikariDataSource::class.java)
|
||||
.build() as HikariDataSource
|
||||
)
|
||||
.apply { maximumPoolSize = 1 }
|
||||
fun sqliteDataSource(): DataSource = (
|
||||
DataSourceBuilder.create()
|
||||
.driverClassName("org.sqlite.JDBC")
|
||||
.url("jdbc:sqlite:${komgaProperties.database.file}?foreign_keys=on;")
|
||||
.type(HikariDataSource::class.java)
|
||||
.build() as HikariDataSource
|
||||
)
|
||||
.apply { maximumPoolSize = 1 }
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue