diff --git a/uri.go b/uri.go index ee5d23d75..21028fe44 100644 --- a/uri.go +++ b/uri.go @@ -134,6 +134,11 @@ func (u *URI) Normalize() string { return fmt.Sprintf("%s://%s:%d", scheme, u.host, u.port) } +// String returns the address as a string. +func (u URI) String() string { + return fmt.Sprintf("%s://%s:%d", u.scheme, u.host, u.port) +} + // Equals returns true if the checked URI is equivalent to this URI. func (u URI) Equals(other *URI) bool { if other == nil {