fix(backend/storage): codefix

This commit is contained in:
ShiKhu 2022-04-28 19:21:45 +02:00
parent 6d4800feea
commit cb01c3cb28
2 changed files with 3 additions and 3 deletions

View file

@ -5,7 +5,7 @@ import (
"io"
)
func gzipFile(file io.ReadSeeker) io.Reader {
func gzipFile(file io.Reader) io.Reader {
reader, writer := io.Pipe()
go func() {
gw, _ := gzip.NewWriterLevel(writer, gzip.BestSpeed)

View file

@ -8,7 +8,7 @@ import (
"bytes"
"io"
"ioutill"
//"io/ioutil"
"os/signal"
"syscall"
@ -56,7 +56,7 @@ func main() {
log.Printf("File read error: %f", err)
return
}
startReader = bytes.NewBuffer(startBytes)
startReader := bytes.NewBuffer(startBytes)
if err := storage.Upload(gzipFile(startReader), key+"-s", "application/octet-stream", true); err != nil {
log.Fatalf("Storage: start upload failed. %v\n", err)
}