fix: scoutfs multipart cleanup in complete/abort mp

This was previously not including the bucket directory for the
mutlipart temp file cleanup. This fixes leftovers in the tmp
directories after uploading multipart uploads.
This commit is contained in:
Ben McClelland
2025-03-10 13:44:24 -07:00
parent 293e7faf31
commit f77058b817
+2 -2
View File
@@ -352,10 +352,10 @@ func (s *ScoutFS) CompleteMultipartUpload(ctx context.Context, input *s3.Complet
}
// cleanup tmp dirs
os.RemoveAll(upiddir)
os.RemoveAll(filepath.Join(bucket, upiddir))
// use Remove for objdir in case there are still other uploads
// for same object name outstanding
os.Remove(objdir)
os.Remove(filepath.Join(bucket, objdir))
return &s3.CompleteMultipartUploadOutput{
Bucket: &bucket,