Полный продовый фикс HY2XS/Hysteria2: auth DTO, валидация bind, smoke, URI, preflight и env-контракт
This commit is contained in:
@@ -270,19 +270,10 @@ func Hysteria2Url(accountId int64) (string, error) {
|
||||
hysteria2Config.ACME.Domains != nil &&
|
||||
len(hysteria2Config.ACME.Domains) > 0 {
|
||||
urlConfig += fmt.Sprintf("&sni=%s", hysteria2Config.ACME.Domains[0])
|
||||
// shadowrocket
|
||||
urlConfig += fmt.Sprintf("&peer=%s", hysteria2Config.ACME.Domains[0])
|
||||
}
|
||||
|
||||
urlConfig += "&insecure=0"
|
||||
|
||||
if hysteria2Config.Bandwidth != nil &&
|
||||
hysteria2Config.Bandwidth.Down != nil &&
|
||||
*hysteria2Config.Bandwidth.Down != "" {
|
||||
// shadowrocket
|
||||
urlConfig += fmt.Sprintf("&downmbps=%s", url.PathEscape(*hysteria2Config.Bandwidth.Down))
|
||||
}
|
||||
|
||||
hysteria2ConfigRemark, err := dao.GetConfig("key = ?", constant.Hysteria2ConfigRemark)
|
||||
if err != nil {
|
||||
return "", err
|
||||
|
||||
Reference in New Issue
Block a user