mirror of
https://github.com/minio/minio.git
synced 2026-11-18 23:00:19 +00:00
ObjectStorage refactor to take io.Reader instead of []byte
This commit is contained in:
1 parent
c7b4e14f64
commit
19da9760b3
7 files changed
+65
-43
No files matched your search
@@ -1,6 +1,7 @@
|
||||
package gateway
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"errors"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
@@ -212,7 +213,7 @@ func SimpleFileStorageDriver(bucket string, input chan ObjectRequest, config Gat
|
||||
}
|
||||
case "PUT":
|
||||
objectPath := path.Join(bucket, request.path)
|
||||
fileStorage.Put(objectPath, request.object)
|
||||
fileStorage.Put(objectPath, bytes.NewBuffer(request.object))
|
||||
request.callback <- nil
|
||||
default:
|
||||
request.callback <- errors.New("Unexpected message")
|
||||
|
||||
Reference in new issue
Block a user