mirror of
https://github.com/TeaOSLab/EdgeNode.git
synced 2026-01-08 00:45:49 +08:00
修复跳转到HTTPS的自定义端口无法起作用的Bug
This commit is contained in:
@@ -19,11 +19,10 @@ func (this *HTTPRequest) doRedirectToHTTPS(redirectToHTTPSConfig *serverconfigs.
|
||||
} else if redirectToHTTPSConfig.Port > 0 {
|
||||
lastIndex := strings.LastIndex(host, ":")
|
||||
if lastIndex > 0 {
|
||||
if redirectToHTTPSConfig.Port != 443 {
|
||||
host = host[:lastIndex] + ":" + strconv.Itoa(redirectToHTTPSConfig.Port)
|
||||
} else {
|
||||
host = host[:lastIndex]
|
||||
}
|
||||
host = host[:lastIndex]
|
||||
}
|
||||
if redirectToHTTPSConfig.Port != 443 {
|
||||
host = host + ":" + strconv.Itoa(redirectToHTTPSConfig.Port)
|
||||
}
|
||||
} else {
|
||||
lastIndex := strings.LastIndex(host, ":")
|
||||
|
||||
Reference in New Issue
Block a user