Don't retrieve a contact record we've already been given.
This commit is contained in:
parent
c22ef3e79e
commit
34eb81a187
1 changed files with 5 additions and 2 deletions
|
@ -271,8 +271,11 @@ class Profile
|
||||||
$contact = [];
|
$contact = [];
|
||||||
|
|
||||||
if ($is_contact) {
|
if ($is_contact) {
|
||||||
$contact_id = Contact::getIdForURL($profile['nurl'], local_user());
|
if (local_user() && ($profile['uid'] ?? '') != local_user()) {
|
||||||
$contact = Contact::getById($contact_id);
|
$contact = Contact::getById(Contact::getIdForURL($profile['nurl'], local_user()));
|
||||||
|
} else {
|
||||||
|
$contact = $profile;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (empty($profile['nickname'])) {
|
if (empty($profile['nickname'])) {
|
||||||
|
|
Loading…
Reference in a new issue