fix bucket delete

This commit is contained in:
Damodar Lohani committed 2021-09-15 10:39:49 +05:45
1 parent a3a97540f3
commit ccae13ac19
1 file changed
+4 -4
+4 -4
View File
@@ -442,15 +442,15 @@ App::delete('/v1/storage/buckets/:bucketId')
throw new Exception('Bucket not found', 404);
}
if(!$dbForInternal->deleteDocument('buckets', $bucketId)) {
throw new Exception('Failed to remove project from DB', 500);
}
$deletes
->setParam('type', DELETE_TYPE_DOCUMENT)
->setParam('document', $bucket)
;
if(!$dbForInternal->deleteDocument('buckets', $bucketId)) {
throw new Exception('Failed to remove project from DB', 500);
}
$events
->setParam('eventData', $response->output($bucket, Response::MODEL_BUCKET))
;