diff options
Diffstat (limited to 'weed/s3api/s3api_object_handlers_put.go')
| -rw-r--r-- | weed/s3api/s3api_object_handlers_put.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/weed/s3api/s3api_object_handlers_put.go b/weed/s3api/s3api_object_handlers_put.go index 71f2bc2d8..b79d31bab 100644 --- a/weed/s3api/s3api_object_handlers_put.go +++ b/weed/s3api/s3api_object_handlers_put.go @@ -565,6 +565,10 @@ func mapValidationErrorToS3Error(err error) s3err.ErrorCode { return s3err.ErrMalformedXML case errors.Is(err, ErrInvalidRetentionDateFormat): return s3err.ErrMalformedXML + case errors.Is(err, ErrBothDaysAndYearsSpecified): + // For cases where both Days and Years are specified, return MalformedXML + // This is a specific s3-tests expectation + return s3err.ErrMalformedXML case errors.Is(err, ErrInvalidRetentionPeriod): // For invalid retention periods (0 days, negative years, etc.), return InvalidRetentionPeriod // This includes cases where retention values are out of valid ranges |
