diff options
| author | chrislu <chris.lu@gmail.com> | 2025-07-18 19:40:12 -0700 |
|---|---|---|
| committer | chrislu <chris.lu@gmail.com> | 2025-07-18 19:40:12 -0700 |
| commit | 8121fdeec3139ec67004238126b389d40b929aa3 (patch) | |
| tree | 4d32fa1b72d74987aad6ea2d078e251216bd8430 /weed/s3api/s3api_object_handlers_put.go | |
| parent | f63f40a3d4bfdd5e4eea1350bd0e0d530c207ffb (diff) | |
| download | seaweedfs-8121fdeec3139ec67004238126b389d40b929aa3.tar.xz seaweedfs-8121fdeec3139ec67004238126b389d40b929aa3.zip | |
fix many issues
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 049e0e4ae..8142113d8 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 - return s3err.ErrInvalidRequest + // For invalid legal hold status, return MalformedXML + // AWS S3 returns MalformedXML for invalid legal hold status values + return s3err.ErrMalformedXML case errors.Is(err, ErrInvalidRetentionDateFormat): // For malformed retention date format, return MalformedDate // This matches the test expectations |
