mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-03 12:39:25 +01:00
- using new accounts::save instead accounts::create
- not setting change password acl for groups
This commit is contained in:
parent
f397d26d2e
commit
6b2d5676f9
@ -908,7 +908,7 @@
|
|||||||
|
|
||||||
if(!($accountid = $GLOBALS['egw']->accounts->name2id($username)))
|
if(!($accountid = $GLOBALS['egw']->accounts->name2id($username)))
|
||||||
{
|
{
|
||||||
if (!($accountid = $GLOBALS['egw']->accounts->create(array(
|
$account = array(
|
||||||
'account_type' => $group ? 'u' : 'g',
|
'account_type' => $group ? 'u' : 'g',
|
||||||
'account_lid' => $username,
|
'account_lid' => $username,
|
||||||
'account_passwd' => $passwd,
|
'account_passwd' => $passwd,
|
||||||
@ -918,7 +918,8 @@
|
|||||||
'account_primary_group' => $groupid,
|
'account_primary_group' => $groupid,
|
||||||
'account_expires' => -1,
|
'account_expires' => -1,
|
||||||
'account_email' => $email,
|
'account_email' => $email,
|
||||||
))))
|
);
|
||||||
|
if (!($accountid = $GLOBALS['egw']->accounts->save($account)))
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -934,7 +935,7 @@
|
|||||||
|
|
||||||
$GLOBALS['egw']->accounts->set_memberships($memberships,$accountid);
|
$GLOBALS['egw']->accounts->set_memberships($memberships,$accountid);
|
||||||
}
|
}
|
||||||
$this->add_acl('preferences','changepassword',$accountid,(int)$changepw);
|
if (!$group) $this->add_acl('preferences','changepassword',$accountid,(int)$changepw);
|
||||||
|
|
||||||
return $accountid;
|
return $accountid;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user