Skip to content

Commit

Permalink
Add missing methods to OCP\IGroupManager
Browse files Browse the repository at this point in the history
Signed-off-by: jld3103 <jld3103yt@gmail.com>
  • Loading branch information
provokateurin committed Mar 28, 2023
1 parent 0d25cc1 commit 4db16fb
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion apps/provisioning_api/lib/Controller/AUserData.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ abstract class AUserData extends OCSController {
protected $userManager;
/** @var IConfig */
protected $config;
/** @var IGroupManager|Manager */ // FIXME Requires a method that is not on the interface
/** @var IGroupManager|Manager */
protected $groupManager;
/** @var IUserSession */
protected $userSession;
Expand Down
2 changes: 1 addition & 1 deletion lib/private/Group/Manager.php
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ public function displayNamesInGroup($gid, $search = '', $limit = -1, $offset = 0
/**
* @return \OC\SubAdmin
*/
public function getSubAdmin() {
public function getSubAdmin(): \OC\SubAdmin {
if (!$this->subAdmin) {
$this->subAdmin = new \OC\SubAdmin(
$this->userManager,
Expand Down
9 changes: 9 additions & 0 deletions lib/public/IGroupManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -155,4 +155,13 @@ public function isInGroup($userId, $group);
* @since 26.0.0
*/
public function getDisplayName(string $groupId): ?string;

/**
* Get the subadmin of a Nextcloud group
*
* @return \OCP\Group\ISubAdmin
*
* @since 27.0.0
*/
public function getSubAdmin(): \OCP\Group\ISubAdmin;
}

0 comments on commit 4db16fb

Please sign in to comment.