remove unnecessary import

This commit is contained in:
gutmet 2020-10-11 13:26:11 +02:00
parent b298451c1f
commit 555b83d5de
2 changed files with 4 additions and 4 deletions

2
go.mod
View File

@ -1,3 +1,3 @@
module git.gutmet.org/simpleserver.git module git.gutmet.org/simpleserver.git
require git.gutmet.org/goutil.git v0.0.0-20181208191316-76ae04a2662a go 1.14

View File

@ -2,7 +2,7 @@ package simpleserver
import ( import (
"fmt" "fmt"
"git.gutmet.org/goutil.git" "io/ioutil"
"net/http" "net/http"
"os" "os"
"os/signal" "os/signal"
@ -20,8 +20,8 @@ func viewHandler(root string, w http.ResponseWriter, r *http.Request) {
file = filepath.Join(file, "index.html") file = filepath.Join(file, "index.html")
} }
fmt.Println("GET " + file) fmt.Println("GET " + file)
content, _ := goutil.ReadFile(file) content, _ := ioutil.ReadFile(file)
fmt.Fprint(w, content) fmt.Fprint(w, string(content))
} }
func Serve(root string) { func Serve(root string) {