Commit 8380ff34 authored by Rob Pike's avatar Rob Pike

http: remove a TODO due to new behavior of nil maps

R=golang-dev, dsymonds, adg
CC=golang-dev
https://golang.org/cl/4907049
parent e4a89d7c
......@@ -619,8 +619,6 @@ func (r *Request) ParseForm() (err os.Error) {
if r.URL != nil {
r.Form, err = url.ParseQuery(r.URL.RawQuery)
} else {
r.Form = make(url.Values) // TODO: remove when nil maps work.
}
if r.Method == "POST" {
if r.Body == nil {
......@@ -645,6 +643,9 @@ func (r *Request) ParseForm() (err os.Error) {
if err == nil {
err = e
}
if r.Form == nil {
r.Form = make(url.Values)
}
// Copy values into r.Form. TODO: make this smoother.
for k, vs := range newValues {
for _, value := range vs {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment