mirror of
https://github.com/go-kratos/kratos.git
synced 2025-03-31 22:05:08 +02:00
Update endpoint.go (#2012)
This commit is contained in:
parent
2ee49311c1
commit
c412d65f57
@ -21,10 +21,8 @@ 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…
x
Reference in New Issue
Block a user