mirror of
https://github.com/minio/minio.git
synced 2025-11-08 21:24:55 -05:00
Implement S3 Style ErrorCodes and Response
This patchset also brings in lot of cleanup in terms of minioapi codebase
This commit is contained in:
@@ -21,6 +21,7 @@ import (
|
||||
"crypto/sha256"
|
||||
"fmt"
|
||||
"io"
|
||||
"log"
|
||||
"sort"
|
||||
"strings"
|
||||
"time"
|
||||
@@ -51,6 +52,7 @@ func (storage *storage) CopyObjectToWriter(w io.Writer, bucket string, object st
|
||||
if val, ok := storage.objectdata[key]; ok {
|
||||
objectBuffer := bytes.NewBuffer(val.data)
|
||||
written, err := io.Copy(w, objectBuffer)
|
||||
log.Println("I am here")
|
||||
return written, err
|
||||
} else {
|
||||
return 0, mstorage.ObjectNotFound{Bucket: bucket, Object: object}
|
||||
|
||||
Reference in New Issue
Block a user