From 23517ea6205e293f204119a2a65207c8ea941a2f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jarkko=20P=C3=B6yry?= Date: Fri, 26 Dec 2025 23:43:57 +0200 Subject: [PATCH] Fix off-by-one in getloc. --- wled00/data/common.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wled00/data/common.js b/wled00/data/common.js index 5f73c946d8..575133a5f0 100644 --- a/wled00/data/common.js +++ b/wled00/data/common.js @@ -118,7 +118,7 @@ function getLoc() { let paths = path.slice(1,path.endsWith('/')?-1:undefined).split("/"); if (paths.length > 1) paths.pop(); // remove subpage (or "settings") if (paths.length > 0 && paths[paths.length-1]=="settings") paths.pop(); // remove "settings" - if (paths.length > 1) { + if (paths.length > 0) { locproto = l.protocol; loc = true; locip = l.hostname + (l.port ? ":" + l.port : "") + "/" + paths.join('/');