From 85d6295365dd69ca3e74c5b168e2a146129860d6 Mon Sep 17 00:00:00 2001 From: AzenKain Date: Thu, 9 Apr 2026 19:07:45 +0700 Subject: [PATCH] UPDATE: fix bug --- pkg/storage/s3.go | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/pkg/storage/s3.go b/pkg/storage/s3.go index c34c09f..8cf6f9b 100644 --- a/pkg/storage/s3.go +++ b/pkg/storage/s3.go @@ -90,10 +90,7 @@ func NewS3Storage() (Storage, error) { client := s3.NewFromConfig(cfg, func(o *s3.Options) { o.BaseEndpoint = aws.String(endpoint) o.UsePathStyle = true - o.RequestChecksumCalculation = aws.RequestChecksumCalculationWhenRequired - o.ResponseChecksumValidation = aws.ResponseChecksumValidationWhenRequired }) - return &s3Storage{ client: client, ps: s3.NewPresignClient(client), @@ -109,10 +106,9 @@ func (s *s3Storage) Move(ctx context.Context, src *MoveOptions, dest *MoveOption copySource := fmt.Sprintf("%s/%s", src.Bucket, url.PathEscape(src.Key)) _, err := s.client.CopyObject(ctx, &s3.CopyObjectInput{ - Bucket: aws.String(dest.Bucket), - Key: aws.String(dest.Key), - CopySource: aws.String(copySource), - MetadataDirective: types.MetadataDirectiveCopy, + Bucket: aws.String(dest.Bucket), + Key: aws.String(dest.Key), + CopySource: aws.String(copySource), }) if err != nil { return fmt.Errorf("failed to copy object: %w", err)