forked from TrueCloudLab/frostfs-s3-gw
[#595] Simplify encryption.Params struct
Signed-off-by: Denis Kirillov <denis@nspcc.ru>
This commit is contained in:
parent
94a6a55919
commit
7ab473a688
3 changed files with 14 additions and 11 deletions
|
@ -334,7 +334,12 @@ func (h handler) formEncryptionParams(header http.Header) (enc encryption.Params
|
|||
return enc, errors.GetAPIError(errors.ErrSSECustomerKeyMD5Mismatch)
|
||||
}
|
||||
|
||||
return encryption.NewParams(key)
|
||||
params, err := encryption.NewParams(key)
|
||||
if err == nil {
|
||||
enc = *params
|
||||
}
|
||||
|
||||
return enc, err
|
||||
}
|
||||
|
||||
func (h *handler) PostObject(w http.ResponseWriter, r *http.Request) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue