Update error response when heal is not implemented (#5383)

This commit is contained in:
Aditya Manthramurthy
2018-01-11 10:21:41 -08:00
committed by kannappanr
parent 1b721d76b1
commit 8e4eb591c1
2 changed files with 43 additions and 1 deletions

View File

@@ -181,6 +181,7 @@ const (
ErrAdminCredentialsMismatch
ErrInsecureClientRequest
ErrObjectTampered
ErrHealNotImplemented
)
// error code to APIError structure, these fields carry respective
@@ -756,6 +757,11 @@ var errorCodeResponse = map[APIErrorCode]APIError{
Description: errObjectTampered.Error(),
HTTPStatusCode: http.StatusPartialContent,
},
ErrHealNotImplemented: {
Code: "XMinioHealNotImplemented",
Description: "This server does not implement heal functionality.",
HTTPStatusCode: http.StatusBadRequest,
},
ErrMaximumExpires: {
Code: "AuthorizationQueryParametersError",
Description: "X-Amz-Expires must be less than a week (in seconds); that is, the given X-Amz-Expires must be less than 604800 seconds",