mirror of
https://github.com/golang/go
synced 2024-11-18 21:44:45 -07:00
net/url: document that Query returns only valid values
Fixes #19110 Change-Id: I291fa4ec3c61145162acd019e3f0e5dd3d7c97e9 Reviewed-on: https://go-review.googlesource.com/37194 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
parent
6cfc3b25e9
commit
1e69aefb7e
@ -974,6 +974,8 @@ func (u *URL) ResolveReference(ref *URL) *URL {
|
||||
}
|
||||
|
||||
// Query parses RawQuery and returns the corresponding values.
|
||||
// It silently discards malformed value pairs.
|
||||
// To check errors use ParseQuery.
|
||||
func (u *URL) Query() Values {
|
||||
v, _ := ParseQuery(u.RawQuery)
|
||||
return v
|
||||
|
Loading…
Reference in New Issue
Block a user