Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/MHSanaei/3x-ui.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHamidreza Ghavami <70919649+hamid-gh98@users.noreply.github.com>2023-05-31 00:17:07 +0300
committerHamidreza Ghavami <70919649+hamid-gh98@users.noreply.github.com>2023-05-31 00:29:41 +0300
commitb203067dfd416bd45d34cc2dbaad85ab51fcb085 (patch)
treef9243bf31ea112fc6c51a53f9b3bcd76a18b2f1f /web/html/xui/inbound_info_modal.html
parent1c9fc9422e304c8710b56e9719960e429e7a1878 (diff)
fix urls + use the new buildURL func
Diffstat (limited to 'web/html/xui/inbound_info_modal.html')
-rw-r--r--web/html/xui/inbound_info_modal.html8
1 files changed, 2 insertions, 6 deletions
diff --git a/web/html/xui/inbound_info_modal.html b/web/html/xui/inbound_info_modal.html
index b7b3436b..23bd5af1 100644
--- a/web/html/xui/inbound_info_modal.html
+++ b/web/html/xui/inbound_info_modal.html
@@ -253,12 +253,8 @@
infoModal.visible = false;
},
genSubLink(subID) {
- protocol = app.subSettings.tls ? "https://" : "http://";
- hostName = app.subSettings.domain === "" ? window.location.hostname : app.subSettings.domain;
- subPort = app.subSettings.port;
- port = (subPort === 443 && app.subSettings.tls) || (subPort === 80 && !app.subSettings.tls) ? "" : ":" + String(subPort);
- subPath = app.subSettings.path;
- return protocol + hostName + port + subPath + subID;
+ const { domain: host, port, tls: isTLS, path: base } = app.subSettings;
+ return buildURL({ host, port, isTLS, base, path: subID });
}
};