This commit is contained in:
Aria Moradi
2021-09-18 20:30:56 +04:30
parent 006efbbb77
commit 6d46d4b3da
9 changed files with 34 additions and 23 deletions

View File

@@ -71,9 +71,10 @@ object ExtensionController {
/** icon for extension named `apkName` */
fun icon(ctx: Context) {
val apkName = ctx.pathParam("apkName")
val useCache = ctx.queryParam("useCache")?.toBoolean() ?: true
ctx.future(
future { Extension.getExtensionIcon(apkName) }
future { Extension.getExtensionIcon(apkName, useCache) }
.thenApply {
ctx.header("content-type", it.second)
it.first