From 86398d1efe28c1f0bf9929b5410a0a655defbc6c Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Thu, 26 Mar 2020 11:05:54 -0700 Subject: [PATCH] S3 API: set deletion to recursive fix https://github.com/chrislusf/seaweedfs/issues/1251 --- weed/s3api/s3api_object_handlers.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/weed/s3api/s3api_object_handlers.go b/weed/s3api/s3api_object_handlers.go index 6a1b67d27..300441ef2 100644 --- a/weed/s3api/s3api_object_handlers.go +++ b/weed/s3api/s3api_object_handlers.go @@ -173,7 +173,7 @@ func (s3a *S3ApiServer) DeleteMultipleObjectsHandler(w http.ResponseWriter, r *h for _, object := range deleteObjects.Objects { lastSeparator := strings.LastIndex(object.ObjectName, "/") - parentDirectoryPath, entryName, isDeleteData, isRecursive := "/", object.ObjectName, true, false + parentDirectoryPath, entryName, isDeleteData, isRecursive := "/", object.ObjectName, true, true if lastSeparator > 0 && lastSeparator+1 < len(object.ObjectName) { entryName = object.ObjectName[lastSeparator+1:] parentDirectoryPath = "/" + object.ObjectName[:lastSeparator]