From 5cda5845685a0d8f6958c802e6173575360fe63f Mon Sep 17 00:00:00 2001 From: schroda <50052685+schroda@users.noreply.github.com> Date: Sat, 2 May 2026 23:21:23 +0200 Subject: [PATCH] Inject html base tag directly (#1967) Using a script to inject the base tag is unnecessarily complex as well as it is introducing an issue where the initial requests will potentially fail, due to the base tag not being injected yet. See https://github.com/Suwayomi/Suwayomi-WebUI/issues/1096, same issue applies when a subpath is set up which can't be fixed on the client side --- .../tachidesk/server/util/WebInterfaceManager.kt | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/server/src/main/kotlin/suwayomi/tachidesk/server/util/WebInterfaceManager.kt b/server/src/main/kotlin/suwayomi/tachidesk/server/util/WebInterfaceManager.kt index c3d26a76..7b788ab2 100644 --- a/server/src/main/kotlin/suwayomi/tachidesk/server/util/WebInterfaceManager.kt +++ b/server/src/main/kotlin/suwayomi/tachidesk/server/util/WebInterfaceManager.kt @@ -206,20 +206,12 @@ object WebInterfaceManager { if (ServerSubpath.isDefined() && orgIndexHtml.exists()) { val originalIndexHtml = orgIndexHtml.readText() - val subpathInjectionScript = - """ - - """.trimIndent() + val subpathInjectionBaseTag = "" val indexHtmlWithSubpathInjection = originalIndexHtml.replace( "", - "$subpathInjectionScript", + "$subpathInjectionBaseTag", ) orgIndexHtml.writeText(indexHtmlWithSubpathInjection)