fixed removing of memberUid on forced sync
This commit is contained in:
parent
9394eeeabd
commit
cb58a27972
|
@ -201,7 +201,7 @@ class posixGroup extends baseModule implements passwordService {
|
||||||
if ($this->autoAddObjectClasses || (isset($this->attributes['objectClass']) && in_array('posixGroup', $this->attributes['objectClass']))) {
|
if ($this->autoAddObjectClasses || (isset($this->attributes['objectClass']) && in_array('posixGroup', $this->attributes['objectClass']))) {
|
||||||
// auto sync group members
|
// auto sync group members
|
||||||
if ($this->isBooleanConfigOptionSet('posixGroup_autoSyncGon')) {
|
if ($this->isBooleanConfigOptionSet('posixGroup_autoSyncGon')) {
|
||||||
$this->syncGon();
|
$this->syncGon(true);
|
||||||
}
|
}
|
||||||
// group name
|
// group name
|
||||||
if ($this->manageCnAndDescription($modules)) {
|
if ($this->manageCnAndDescription($modules)) {
|
||||||
|
@ -972,10 +972,11 @@ class posixGroup extends baseModule implements passwordService {
|
||||||
/**
|
/**
|
||||||
* Syncs with group of names members.
|
* Syncs with group of names members.
|
||||||
*
|
*
|
||||||
|
* @param bool $forceDelete force deletion of members
|
||||||
* @return array list of status messages
|
* @return array list of status messages
|
||||||
*/
|
*/
|
||||||
protected function syncGon() {
|
protected function syncGon($forceDelete = false) {
|
||||||
$delete = isset($_POST['syncGON_delete']) && ($_POST['syncGON_delete'] == 'on');
|
$delete = $forceDelete || (isset($_POST['syncGON_delete']) && ($_POST['syncGON_delete'] == 'on'));
|
||||||
$return = array();
|
$return = array();
|
||||||
$gon = $this->getAccountContainer()->getAccountModule('groupOfNames');
|
$gon = $this->getAccountContainer()->getAccountModule('groupOfNames');
|
||||||
if ($gon == null) {
|
if ($gon == null) {
|
||||||
|
@ -1083,7 +1084,7 @@ class posixGroup extends baseModule implements passwordService {
|
||||||
}
|
}
|
||||||
// auto sync group members
|
// auto sync group members
|
||||||
if ($this->isBooleanConfigOptionSet('posixGroup_autoSyncGon')) {
|
if ($this->isBooleanConfigOptionSet('posixGroup_autoSyncGon')) {
|
||||||
$this->syncGon();
|
$this->syncGon(true);
|
||||||
}
|
}
|
||||||
$return = $this->getAccountContainer()->save_module_attributes($this->attributes, $this->orig);
|
$return = $this->getAccountContainer()->save_module_attributes($this->attributes, $this->orig);
|
||||||
// Change gids of users and hosts?
|
// Change gids of users and hosts?
|
||||||
|
|
Loading…
Reference in New Issue