mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-04-23 20:49:13 -05:00
add delete home space permission to admin role
Signed-off-by: Christian Richter <crichter@owncloud.com>
This commit is contained in:
@@ -252,6 +252,9 @@ func (g Graph) DeleteUser(w http.ResponseWriter, r *http.Request) {
|
||||
for _, sp := range lspr.GetStorageSpaces() {
|
||||
if sp.SpaceType == "personal" {
|
||||
if sp.Owner.Id.OpaqueId == userID {
|
||||
// TODO: check if request contains a homespace and if, check if requesting user has the privilege to
|
||||
// delete it and make sure it is not deleting its own homespace
|
||||
// needs modification of the cs3api
|
||||
_, err := g.gatewayClient.DeleteStorageSpace(r.Context(), &storageprovider.DeleteStorageSpaceRequest{
|
||||
Opaque: opaque,
|
||||
Id: &storageprovider.StorageSpaceId{
|
||||
|
||||
Reference in New Issue
Block a user