"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files
Go azure-blobazure-blob-storageazure-filesbackblaze-b2cloud-storagedropboxencryptionftpfuse-filesystemgogolanggoogle-cloud-storagegoogle-driveonedriveopenstack-swiftrclones3sftpsyncwebdav
s3: Fix corrupting Content-Type on mod time update
Joseph Spurrierfe0289f2f5ea
diff --git a/s3/s3.go b/s3/s3.goindex 99a5a310e..de2e3e416 100644--- a/s3/s3.go+++ b/s3/s3.go@@ -644,6 +644,9 @@ func (o *Object) SetModTime(modTime time.Time) {}o.meta[metaMtime] = aws.String(swift.TimeToFloatString(modTime))+ // Guess the content type+ contentType := fs.MimeType(o)+// Copy the object to itself to update the metadatakey := o.fs.root + o.remotesourceKey := o.fs.bucket + "/" + key@@ -652,6 +655,7 @@ func (o *Object) SetModTime(modTime time.Time) {Bucket: &o.fs.bucket,ACL: &o.fs.perm,Key: &key,+ ContentType: &contentType,CopySource: &sourceKey,Metadata: o.meta,MetadataDirective: &directive,