Update comment for SplitHostPort

This commit is contained in:
Mark McGranaghan 2015-02-14 07:16:07 -08:00
parent 497e99d58b
commit ad69440af1

View File

@ -32,8 +32,7 @@ func main() {
fmt.Println(p)
// The `Host` contains both the hostname and the port,
// if present. `Split` the `Host` manually to extract
// the port.
// if present. Use `SplitHostPort` to extract them.
fmt.Println(u.Host)
host, port, _ := net.SplitHostPort(u.Host)
fmt.Println(host)