Update endpoint.go (#2012)

status-code-override
songzhibin97 3 years ago committed by chenzhihui
parent 291f0f3ad0
commit fa3d9c3fc1
  1. 4
      internal/endpoint/endpoint.go

@ -21,12 +21,10 @@ func ParseEndpoint(endpoints []string, scheme string, isSecure bool) (string, er
if err != nil { if err != nil {
return "", err return "", err
} }
if u.Scheme == scheme { if u.Scheme == scheme && IsSecure(u) == isSecure {
if IsSecure(u) == isSecure {
return u.Host, nil return u.Host, nil
} }
} }
}
return "", nil return "", nil
} }

Loading…
Cancel
Save