1
0

Fix frontend from other loc

This commit is contained in:
Jose
2025-03-17 01:59:55 +01:00
parent 11cc23b0b9
commit 13d0a277cc
2 changed files with 8 additions and 1 deletions

View File

@@ -70,6 +70,12 @@ public class ConfigManager {
".contaminus/");
}
public String getWebRoot() {
return config.getProperty("web.root") != null ?
config.getProperty("web.root") :
getBaseDir() + "webroot/";
}
public static OSType getOS() {
String os = System.getProperty("os.name").toLowerCase();
if (os.contains("win")) {

View File

@@ -22,7 +22,8 @@ public class WebServerVerticle extends AbstractVerticle {
router.route("/*")
.handler(
StaticHandler.create("webroot")
StaticHandler.create(configManager.getWebRoot())
.setCachingEnabled(false)
.setDefaultContentEncoding("UTF-8")
);