An empty user id does not have children
This commit is contained in:
parent
08c4d7eedc
commit
7dd5ea42e9
|
@ -1505,6 +1505,10 @@ class User
|
|||
*/
|
||||
public static function identities($uid)
|
||||
{
|
||||
if (empty($uid)) {
|
||||
return [];
|
||||
}
|
||||
|
||||
$identities = [];
|
||||
|
||||
$user = DBA::selectFirst('user', ['uid', 'nickname', 'username', 'parent-uid'], ['uid' => $uid]);
|
||||
|
|
|
@ -342,9 +342,11 @@ class Authentication
|
|||
$this->dba->update('user', ['login_date' => DateTimeFormat::utcNow()], ['uid' => $user_record['uid']]);
|
||||
|
||||
// Set the login date for all identities of the user
|
||||
if (!empty($masterUid)) {
|
||||
$this->dba->update('user', ['login_date' => DateTimeFormat::utcNow()],
|
||||
['parent-uid' => $masterUid, 'account_removed' => false]);
|
||||
}
|
||||
}
|
||||
|
||||
if ($login_initial) {
|
||||
/*
|
||||
|
|
Loading…
Reference in New Issue
Block a user