|
@@ 1102-1106 (lines=5) @@
|
| 1099 |
|
*/ |
| 1100 |
|
public function createGroup($gid) { |
| 1101 |
|
if ($this->groupPluginManager->implementsActions(GroupInterface::CREATE_GROUP)) { |
| 1102 |
|
if ($dn = $this->groupPluginManager->createGroup($gid)) { |
| 1103 |
|
//updates group mapping |
| 1104 |
|
$this->access->dn2ocname($dn, $gid, false); |
| 1105 |
|
$this->access->connection->writeToCache("groupExists".$gid, true); |
| 1106 |
|
} |
| 1107 |
|
return $dn != null; |
| 1108 |
|
} |
| 1109 |
|
throw new \Exception('Could not create group in LDAP backend.'); |
|
@@ 1120-1124 (lines=5) @@
|
| 1117 |
|
*/ |
| 1118 |
|
public function deleteGroup($gid) { |
| 1119 |
|
if ($this->groupPluginManager->implementsActions(GroupInterface::DELETE_GROUP)) { |
| 1120 |
|
if ($ret = $this->groupPluginManager->deleteGroup($gid)) { |
| 1121 |
|
#delete group in nextcloud internal db |
| 1122 |
|
$this->access->getGroupMapper()->unmap($gid); |
| 1123 |
|
$this->access->connection->writeToCache("groupExists".$gid, false); |
| 1124 |
|
} |
| 1125 |
|
return $ret; |
| 1126 |
|
} |
| 1127 |
|
throw new \Exception('Could not delete group in LDAP backend.'); |