mirror of
https://github.com/Suwayomi/Suwayomi-Server.git
synced 2026-07-15 16:54:09 -05:00
Implement extension store
This commit is contained in:
@@ -165,17 +165,17 @@ object ExtensionController {
|
||||
/** icon for extension named `apkName` */
|
||||
val icon =
|
||||
handler(
|
||||
pathParam<String>("apkName"),
|
||||
pathParam<String>("pkgName"),
|
||||
documentWith = {
|
||||
withOperation {
|
||||
summary("Extension icon")
|
||||
description("Icon for extension named `apkName`")
|
||||
}
|
||||
},
|
||||
behaviorOf = { ctx, apkName ->
|
||||
behaviorOf = { ctx, pkgName ->
|
||||
ctx.getAttribute(Attribute.TachideskUser).requireUser()
|
||||
ctx.future {
|
||||
future { Extension.getExtensionIcon(apkName) }
|
||||
future { Extension.getExtensionIcon(pkgName) }
|
||||
.thenApply {
|
||||
ctx.header("content-type", it.second)
|
||||
val httpCacheSeconds = 365.days.inWholeSeconds
|
||||
|
||||
Reference in New Issue
Block a user