Fix TLS insecure

This commit is contained in:
Hellojack 2022-08-24 15:54:42 +08:00 committed by GitHub
parent 553f78ed55
commit ed4a83efe6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -32,7 +32,7 @@ func TLSConfig(serverAddress string, options option.OutboundTLSOptions) (*tls.Co
serverName = serverAddress serverName = serverAddress
} }
} }
if serverName == "" && options.Insecure { if serverName == "" && !options.Insecure {
return nil, E.New("missing server_name or insecure=true") return nil, E.New("missing server_name or insecure=true")
} }