Skip to content

Commit

Permalink
fix(FolderController): Require Groupfolder admin on all endpoints
Browse files Browse the repository at this point in the history
Signed-off-by: provokateurin <[email protected]>
  • Loading branch information
provokateurin committed Jan 6, 2025
1 parent ebcb626 commit 394f011
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/Controller/FolderController.php
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ private function formatFolder(array $folder): array {
/**
* Gets all Groupfolders
* @NoAdminRequired
* @RequireGroupFolderAdmin
* @param bool $applicable Filter by applicable groups
* @return DataResponse<Http::STATUS_OK, array<string, GroupFoldersFolder>, array{}>
* @throws OCSNotFoundException Storage not found
Expand Down Expand Up @@ -132,6 +133,7 @@ public function getFolders(bool $applicable = false): DataResponse {
/**
* Gets a Groupfolder by ID
* @NoAdminRequired
* @RequireGroupFolderAdmin
* @param int $id ID of the Groupfolder
* @return DataResponse<Http::STATUS_OK, GroupFoldersFolder, array{}>|DataResponse<Http::STATUS_NOT_FOUND, list<empty>, array{}>
* @throws OCSNotFoundException Groupfolder not found
Expand Down Expand Up @@ -423,6 +425,7 @@ private function folderDataForXML(array $data): array {
/**
* Searches for matching ACL mappings
* @NoAdminRequired
* @RequireGroupFolderAdmin
* @param int $id The ID of the Groupfolder
* @param string $search String to search by
* @return DataResponse<Http::STATUS_OK, array{users: list<GroupFoldersUser>, groups: list<GroupFoldersGroup>}, array{}>
Expand Down

0 comments on commit 394f011

Please sign in to comment.