From e197051c6e306cd4b724a190e84b82e5c8570198 Mon Sep 17 00:00:00 2001 From: Eliot Whalan Date: Sat, 11 Jun 2016 11:26:12 +1000 Subject: [PATCH] Remove fmt --- main.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/main.go b/main.go index 59066df..492f456 100644 --- a/main.go +++ b/main.go @@ -1,7 +1,6 @@ package main import ( - "fmt" "github.com/dchest/uniuri" "io" "io/ioutil" @@ -57,11 +56,10 @@ func save(buf []byte) string { func pasteHandler(w http.ResponseWriter, r *http.Request) { switch r.Method { case "GET": - fmt.Fprintf(w, text) + io.WriteString(w, text) case "POST": buf, _ := ioutil.ReadAll(r.Body) io.WriteString(w, address+save(buf)+"\n") - case "DELETE": // Remove the record. }