From e99a4742bb3d2d401449be93a7767eac8820eef4 Mon Sep 17 00:00:00 2001 From: Michael Date: Sat, 1 Feb 2020 15:41:17 +0000 Subject: [PATCH] removed file Signed-off-by: Michael --- file.go | 23 ----------------------- 1 file changed, 23 deletions(-) delete mode 100644 file.go diff --git a/file.go b/file.go deleted file mode 100644 index 8bf0b99..0000000 --- a/file.go +++ /dev/null @@ -1,23 +0,0 @@ -package request - -import ( - "io/ioutil" - "log" - "os" -) - -// File reads data from file -func File(path string) ([]byte, error) { - file, err := os.Open(path) - if err != nil { - log.Println("Error reading request. ", err) - return nil, err - } - defer file.Close() - byteValue, _ := ioutil.ReadAll(file) - if err != nil { - log.Println(err) - return nil, err - } - return byteValue, nil -}