diff options
author | ache <ache@ache.one> | 2021-04-17 02:21:12 +0200 |
---|---|---|
committer | ache <ache@ache.one> | 2021-04-17 02:21:12 +0200 |
commit | 939ba84c43c6c740bff027bd7eeb1b175a96fd46 (patch) | |
tree | 5307ef7a2a58cf1251744e12363bcf6bc348dc76 | |
parent | Trully Allow Hidden File / Directory (diff) |
Log moving
-rw-r--r-- | server.go | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -160,7 +160,9 @@ func handleGet( w http.ResponseWriter, r *http.Request, headOnly bool) { } name := "davy - " + filename err = tmpl.Execute(w, Collection{ name, cols, files}) - fmt.Println(err) + if err != nil { + fmt.Println(err) + } case stat.Mode().IsRegular(): if !headOnly { @@ -292,7 +294,7 @@ func handleOptions( w http.ResponseWriter, r *http.Request) { w.WriteHeader(http.StatusOK); } func handleCopy( w http.ResponseWriter, r *http.Request) { - fmt.Println("The body of the request isn't empty. It should be.") + fmt.Println(w, "The body of the request isn't empty. It should be.") } func handleMove( w http.ResponseWriter, r *http.Request) { filename := r.URL.Path[1:] @@ -304,6 +306,7 @@ func handleMove( w http.ResponseWriter, r *http.Request) { } if verifyEmptyBody(w, r) != nil { return } + fmt.Println("Moving ", filename, " => ", dest) fmt.Println(dest) return |