Update dependency io.javalin:javalin to v6 (#1152)

* Update dependency io.javalin:javalin to v6

* Simple compile fixes

* Simple compile fixes pass 2

* Add results to futures

* Setup jetty server and api routes

* Setup Cors

* Setup basic auth

* Documentation stubs

* Replace chapter mutex cache

* Fix compile

* Disable Jetty Logging

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Syer10 <syer10@users.noreply.github.com>
This commit is contained in:
renovate[bot]
2024-11-17 15:00:53 -05:00
committed by GitHub
parent ba1c2845b6
commit 9cd8cb3d54
31 changed files with 478 additions and 363 deletions

View File

@@ -7,7 +7,7 @@ package suwayomi.tachidesk.global.controller
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
import io.javalin.http.HttpCode
import io.javalin.http.HttpStatus
import suwayomi.tachidesk.global.impl.About
import suwayomi.tachidesk.global.impl.AboutDataClass
import suwayomi.tachidesk.global.impl.AppUpdate
@@ -31,7 +31,7 @@ object SettingsController {
ctx.json(About.getAbout())
},
withResults = {
json<AboutDataClass>(HttpCode.OK)
json<AboutDataClass>(HttpStatus.OK)
},
)
@@ -45,12 +45,13 @@ object SettingsController {
}
},
behaviorOf = { ctx ->
ctx.future(
future { AppUpdate.checkUpdate() },
)
ctx.future {
future { AppUpdate.checkUpdate() }
.thenApply { ctx.json(it) }
}
},
withResults = {
json<Array<UpdateDataClass>>(HttpCode.OK)
json<Array<UpdateDataClass>>(HttpStatus.OK)
},
)
}