Skip to content

Commit

Permalink
re-order config options
Browse files Browse the repository at this point in the history
  • Loading branch information
AriaMoradi committed Feb 12, 2023
1 parent 555f73b commit f3c2ee4
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,6 @@ fun getChapterCachePath(mangaId: Int, chapterId: Int): String {
return applicationDirs.tempMangaCacheRoot + "/" + getChapterDir(mangaId, chapterId)
}

// (if (useTempCache) applicationDirs.tempCacheRoot else )

/** return value says if rename/move was successful */
fun updateMangaDownloadDir(mangaId: Int, newTitle: String): Boolean {
val mangaEntry = getMangaEntry(mangaId)
Expand Down
17 changes: 8 additions & 9 deletions server/src/main/kotlin/suwayomi/tachidesk/server/ServerConfig.kt
Original file line number Diff line number Diff line change
Expand Up @@ -19,30 +19,29 @@ class ServerConfig(config: Config, moduleName: String = MODULE_NAME) : SystemPro

// proxy
val socksProxyEnabled: Boolean by overridableConfig

val socksProxyHost: String by overridableConfig
val socksProxyPort: String by overridableConfig

// downloader
val downloadAsCbz: Boolean by overridableConfig

// misc
val debugLogsEnabled: Boolean = debugLogsEnabled(GlobalConfigManager.config)
val systemTrayEnabled: Boolean by overridableConfig
val downloadsPath: String by overridableConfig

// webUI
val webUIEnabled: Boolean by overridableConfig
val webUIFlavor: String by overridableConfig
val initialOpenInBrowserEnabled: Boolean by overridableConfig
val webUIInterface: String by overridableConfig
val electronPath: String by overridableConfig

// downloader
val downloadAsCbz: Boolean by overridableConfig
val downloadsPath: String by overridableConfig

// Authentication
val basicAuthEnabled: Boolean by overridableConfig
val basicAuthUsername: String by overridableConfig
val basicAuthPassword: String by overridableConfig

// misc
val debugLogsEnabled: Boolean = debugLogsEnabled(GlobalConfigManager.config)
val systemTrayEnabled: Boolean by overridableConfig

companion object {
fun register(config: Config) = ServerConfig(config.getConfig(MODULE_NAME))
}
Expand Down
8 changes: 4 additions & 4 deletions server/src/main/resources/server-reference.conf
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@ server.initialOpenInBrowserEnabled = true
server.webUIInterface = "browser" # "browser" or "electron"
server.electronPath = ""

# downloader
server.downloadAsCbz = false
server.downloadsPath = ""

# Authentication
server.basicAuthEnabled = false
server.basicAuthUsername = ""
server.basicAuthPassword = ""

# downloader
server.downloadAsCbz = false

# misc
server.debugLogsEnabled = false
server.systemTrayEnabled = true
server.downloadsPath = ""

0 comments on commit f3c2ee4

Please sign in to comment.