Merge pull request #10407 from annando/add-profile
Add a profile entry if missing
This commit is contained in:
commit
9039d812f1
1 changed files with 6 additions and 1 deletions
|
@ -391,7 +391,12 @@ class User
|
||||||
if (!DBA::exists('user', ['uid' => $uid]) || !$repairMissing) {
|
if (!DBA::exists('user', ['uid' => $uid]) || !$repairMissing) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
if (!DBA::exists('profile', ['uid' => $uid])) {
|
||||||
|
DBA::insert('profile', ['uid' => $uid]);
|
||||||
|
}
|
||||||
|
if (!DBA::exists('contact', ['uid' => $uid, 'self' => true])) {
|
||||||
Contact::createSelfFromUserId($uid);
|
Contact::createSelfFromUserId($uid);
|
||||||
|
}
|
||||||
$owner = self::getOwnerDataById($uid, false);
|
$owner = self::getOwnerDataById($uid, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue