Remove http/s standard port numbers (#3945)
This commit is contained in:
parent
bda2c7abc3
commit
55910059ed
1 changed files with 3 additions and 0 deletions
|
|
@ -53,6 +53,9 @@ type networkConfig struct {
|
|||
}
|
||||
|
||||
func (c networkConfig) HostPort() string {
|
||||
if c.Schema == "http" && c.Port == 80 || c.Schema == "https" && c.Port == 443 {
|
||||
return c.Host
|
||||
}
|
||||
return net.JoinHostPort(c.Host, strconv.Itoa(c.Port))
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue