fix(aliyundrive_open): date format on uploading (#5151)

(cherry picked from commit 88f815979ac91caa8bc425a2ff9a18bbd8a2e736)
This commit is contained in:
Sean 2023-09-03 18:12:05 +08:00 committed by GitHub
parent 37dffd0fce
commit 8e40465e86
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -148,9 +148,8 @@ func (d *AliyundriveOpen) upload(ctx context.Context, dstDir model.Obj, stream m
// Part Size Unit: Bytes, Default: 20MB,
// Maximum number of slices 10,000, ≈195.3125GB
var partSize = calPartSize(stream.GetSize())
const dateFormat = "2006-01-02T15:04:05.999Z"
mtime := stream.ModTime()
mtimeStr := mtime.UTC().Format(dateFormat)
const dateFormat = "2006-01-02T15:04:05.000Z"
mtimeStr := stream.ModTime().UTC().Format(dateFormat)
ctimeStr := stream.CreateTime().UTC().Format(dateFormat)
createData := base.Json{