fixed problems when profile is loaded and extension is not activated
This commit is contained in:
parent
ae3cf886ed
commit
813254f335
|
@ -495,6 +495,25 @@ class asteriskVoicemail extends baseModule implements passwordService {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns a list of modifications which have to be made to the LDAP account.
|
||||||
|
*
|
||||||
|
* @return array list of modifications
|
||||||
|
* <br>This function returns an array with 3 entries:
|
||||||
|
* <br>array( DN1 ('add' => array($attr), 'remove' => array($attr), 'modify' => array($attr)), DN2 .... )
|
||||||
|
* <br>DN is the DN to change. It may be possible to change several DNs (e.g. create a new user and add him to some groups via attribute memberUid)
|
||||||
|
* <br>"add" are attributes which have to be added to LDAP entry
|
||||||
|
* <br>"remove" are attributes which have to be removed from LDAP entry
|
||||||
|
* <br>"modify" are attributes which have to been modified in LDAP entry
|
||||||
|
*/
|
||||||
|
function save_attributes() {
|
||||||
|
if (!in_array('AsteriskVoiceMail', $this->attributes['objectClass']) && !in_array('AsteriskVoiceMail', $this->orig['objectClass'])) {
|
||||||
|
// skip saving if the extension was not added/modified
|
||||||
|
return array();
|
||||||
|
}
|
||||||
|
return $this->getAccountContainer()->save_module_attributes($this->attributes, $this->orig);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This method specifies if a module manages password attributes.
|
* This method specifies if a module manages password attributes.
|
||||||
* @see passwordService::managesPasswordAttributes
|
* @see passwordService::managesPasswordAttributes
|
||||||
|
|
|
@ -596,6 +596,25 @@ class kolabUser extends baseModule {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns a list of modifications which have to be made to the LDAP account.
|
||||||
|
*
|
||||||
|
* @return array list of modifications
|
||||||
|
* <br>This function returns an array with 3 entries:
|
||||||
|
* <br>array( DN1 ('add' => array($attr), 'remove' => array($attr), 'modify' => array($attr)), DN2 .... )
|
||||||
|
* <br>DN is the DN to change. It may be possible to change several DNs (e.g. create a new user and add him to some groups via attribute memberUid)
|
||||||
|
* <br>"add" are attributes which have to be added to LDAP entry
|
||||||
|
* <br>"remove" are attributes which have to be removed from LDAP entry
|
||||||
|
* <br>"modify" are attributes which have to been modified in LDAP entry
|
||||||
|
*/
|
||||||
|
function save_attributes() {
|
||||||
|
if (!in_array('kolabInetOrgPerson', $this->attributes['objectClass']) && !in_array('kolabInetOrgPerson', $this->orig['objectClass'])) {
|
||||||
|
// skip saving if the extension was not added/modified
|
||||||
|
return array();
|
||||||
|
}
|
||||||
|
return $this->getAccountContainer()->save_module_attributes($this->attributes, $this->orig);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* In this function the LDAP account is built up.
|
* In this function the LDAP account is built up.
|
||||||
*
|
*
|
||||||
|
|
Loading…
Reference in New Issue