From 590166f8471dd317400c9b215d5f6387e8daebd3 Mon Sep 17 00:00:00 2001 From: si458 Date: Tue, 8 Oct 2024 08:51:16 +0100 Subject: [PATCH] fix meshaction with foldr based domains #6436 Signed-off-by: si458 --- webserver.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webserver.js b/webserver.js index d370f105..21901080 100644 --- a/webserver.js +++ b/webserver.js @@ -5665,7 +5665,7 @@ module.exports.CreateWebServer = function (parent, db, args, certificates, doneF if (user != null) { meshaction.username = user.name; } if (req.query.key != null) { meshaction.loginKey = req.query.key; } var httpsPort = ((obj.args.aliasport == null) ? obj.args.port : obj.args.aliasport); // Use HTTPS alias port is specified - if (obj.args.lanonly != true) { meshaction.serverUrl = 'wss://' + obj.getWebServerName(domain, req) + ':' + httpsPort + '/' + ((domain.id == '') ? '' : ('/' + domain.id)) + 'meshrelay.ashx'; } + if (obj.args.lanonly != true) { meshaction.serverUrl = 'wss://' + obj.getWebServerName(domain, req) + ':' + httpsPort + '/' + ((domain.id == '') ? '' : (domain.id + '/')) + 'meshrelay.ashx'; } setContentDispositionHeader(res, 'application/octet-stream', 'meshaction.txt', null, 'meshaction.txt'); res.send(JSON.stringify(meshaction, null, ' '));