diff options
Diffstat (limited to 'weed/s3api/s3api_object_handlers_put.go')
| -rw-r--r-- | weed/s3api/s3api_object_handlers_put.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/weed/s3api/s3api_object_handlers_put.go b/weed/s3api/s3api_object_handlers_put.go index 3241802fa..07ddebf43 100644 --- a/weed/s3api/s3api_object_handlers_put.go +++ b/weed/s3api/s3api_object_handlers_put.go @@ -573,9 +573,9 @@ func mapValidationErrorToS3Error(err error) s3err.ErrorCode { // This matches the test expectations return s3err.ErrInvalidRequest case errors.Is(err, ErrInvalidLegalHoldStatus): - // For invalid legal hold status, return InvalidRequest - // This matches the test expectations for invalid parameter values - return s3err.ErrInvalidRequest + // For invalid legal hold status in XML body, return MalformedXML + // AWS S3 treats invalid status values in XML as malformed content + return s3err.ErrMalformedXML case errors.Is(err, ErrInvalidRetentionDateFormat): // For malformed retention date format, return MalformedDate // This matches the test expectations |
