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:
authorMHSanaei <ho3ein.sanaei@gmail.com>2023-04-11 18:53:40 +0300
committerMHSanaei <ho3ein.sanaei@gmail.com>2023-04-11 18:53:40 +0300
commit4e7ad9e6de7520a3ed510fadb9644a47237aeb53 (patch)
tree1132c3cb7513e456b2ae865a68fd4234c5a4fbca /web/service
parent8c40e7281fe40b3dfe40093446a339a99c2f2e1a (diff)
bug fix
Diffstat (limited to 'web/service')
-rw-r--r--web/service/sub.go20
1 files changed, 10 insertions, 10 deletions
diff --git a/web/service/sub.go b/web/service/sub.go
index d1891e14..8d96866c 100644
--- a/web/service/sub.go
+++ b/web/service/sub.go
@@ -300,7 +300,7 @@ func (s *SubService) genVlessLink(inbound *model.Inbound, email string) string {
if security == "xtls" {
params["security"] = "xtls"
- xtlsSetting, _ := stream["xtlsSettings"].(map[string]interface{})
+ xtlsSetting, _ := stream["XTLSSettings"].(map[string]interface{})
alpns, _ := xtlsSetting["alpn"].([]interface{})
var alpn []string
for _, a := range alpns {
@@ -310,15 +310,15 @@ func (s *SubService) genVlessLink(inbound *model.Inbound, email string) string {
params["alpn"] = strings.Join(alpn, ",")
}
- xtlsSettings, _ := searchKey(xtlsSetting, "settings")
+ XTLSSettings, _ := searchKey(xtlsSetting, "settings")
if xtlsSetting != nil {
- if sniValue, ok := searchKey(xtlsSettings, "serverName"); ok {
+ if sniValue, ok := searchKey(XTLSSettings, "serverName"); ok {
params["sni"], _ = sniValue.(string)
}
- if fpValue, ok := searchKey(xtlsSettings, "fingerprint"); ok {
+ if fpValue, ok := searchKey(XTLSSettings, "fingerprint"); ok {
params["fp"], _ = fpValue.(string)
}
- if insecure, ok := searchKey(xtlsSettings, "allowInsecure"); ok {
+ if insecure, ok := searchKey(XTLSSettings, "allowInsecure"); ok {
if insecure.(bool) {
params["allowInsecure"] = "1"
}
@@ -444,7 +444,7 @@ func (s *SubService) genTrojanLink(inbound *model.Inbound, email string) string
if security == "xtls" {
params["security"] = "xtls"
- xtlsSetting, _ := stream["xtlsSettings"].(map[string]interface{})
+ xtlsSetting, _ := stream["XTLSSettings"].(map[string]interface{})
alpns, _ := xtlsSetting["alpn"].([]interface{})
var alpn []string
for _, a := range alpns {
@@ -454,15 +454,15 @@ func (s *SubService) genTrojanLink(inbound *model.Inbound, email string) string
params["alpn"] = strings.Join(alpn, ",")
}
- xtlsSettings, _ := searchKey(xtlsSetting, "settings")
+ XTLSSettings, _ := searchKey(xtlsSetting, "settings")
if xtlsSetting != nil {
- if sniValue, ok := searchKey(xtlsSettings, "serverName"); ok {
+ if sniValue, ok := searchKey(XTLSSettings, "serverName"); ok {
params["sni"], _ = sniValue.(string)
}
- if fpValue, ok := searchKey(xtlsSettings, "fingerprint"); ok {
+ if fpValue, ok := searchKey(XTLSSettings, "fingerprint"); ok {
params["fp"], _ = fpValue.(string)
}
- if insecure, ok := searchKey(xtlsSettings, "allowInsecure"); ok {
+ if insecure, ok := searchKey(XTLSSettings, "allowInsecure"); ok {
if insecure.(bool) {
params["allowInsecure"] = "1"
}