novelty.go

Single word (yes/no) site for app engine in go
git clone https://wehaveforgeathome.hates.computer/novelty.go.git
Log | Files | Refs | LICENSE

commit 186a9d038213706465dc6004e25f2bd85d93565f
parent ab6bb56cd0f3bb62b67fe91782a2210e931643e7
Author: Ryan Wolf <rwolf@borderstylo.com>
Date:   Mon, 26 Mar 2012 00:10:37 -0700

http.Redirect needs a url

Diffstat:
Mnovelty/novelty.go | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/novelty/novelty.go b/novelty/novelty.go @@ -60,12 +60,12 @@ func init() { addRoute("/yes", "GET", func(w http.ResponseWriter, r *http.Request) { answer = "yes" - http.Redirect(w, r, "", http.StatusFound) + http.Redirect(w, r, "/", http.StatusFound) }) addRoute("/no", "GET", func(w http.ResponseWriter, r *http.Request) { answer = "no" - http.Redirect(w, r, "", http.StatusFound) + http.Redirect(w, r, "/", http.StatusFound) }) http.HandleFunc("/", router)