Chec for missing profile first

This commit is contained in:
Michael 2021-06-15 22:01:30 +00:00
parent e994d02791
commit c17f23423f

View File

@ -391,12 +391,12 @@ class User
if (!DBA::exists('user', ['uid' => $uid]) || !$repairMissing) {
return false;
}
if (!DBA::exists('contact', ['uid' => $uid, 'self' => true])) {
Contact::createSelfFromUserId($uid);
}
if (!DBA::exists('profile', ['uid' => $uid])) {
DBA::insert('profile', ['uid' => $uid]);
}
if (!DBA::exists('contact', ['uid' => $uid, 'self' => true])) {
Contact::createSelfFromUserId($uid);
}
$owner = self::getOwnerDataById($uid, false);
}