Merge pull request #12147 from annando/warning
Fix warning: Undefined array key "public"
This commit is contained in:
commit
55365aa4da
2 changed files with 5 additions and 4 deletions
|
@ -39,12 +39,13 @@ class Relationship extends BaseFactory
|
||||||
{
|
{
|
||||||
$cdata = Contact::getPublicAndUserContactID($contactId, $uid);
|
$cdata = Contact::getPublicAndUserContactID($contactId, $uid);
|
||||||
if (!empty($cdata)) {
|
if (!empty($cdata)) {
|
||||||
$cid = $cdata['user'];
|
$cid = $cdata['user'];
|
||||||
|
$pcid = $cdata['public'];
|
||||||
} else {
|
} else {
|
||||||
$cid = $contactId;
|
$pcid = $cid = $contactId;
|
||||||
}
|
}
|
||||||
|
|
||||||
return new RelationshipEntity($cdata['public'], Contact::getById($cid),
|
return new RelationshipEntity($pcid, Contact::getById($cid),
|
||||||
Contact\User::isBlocked($cid, $uid), Contact\User::isIgnored($cid, $uid));
|
Contact\User::isBlocked($cid, $uid), Contact\User::isIgnored($cid, $uid));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -67,7 +67,7 @@ class CheckRelMeProfileLink
|
||||||
Logger::notice('Empty body of the fetched homepage link). Cannot verify the relation to profile of UID %s.', ['uid' => $uid, 'owner homepage' => $owner['homepage']]);
|
Logger::notice('Empty body of the fetched homepage link). Cannot verify the relation to profile of UID %s.', ['uid' => $uid, 'owner homepage' => $owner['homepage']]);
|
||||||
} else {
|
} else {
|
||||||
$doc = new DOMDocument();
|
$doc = new DOMDocument();
|
||||||
$doc->loadHTML($content);
|
@$doc->loadHTML($content);
|
||||||
if (!$doc) {
|
if (!$doc) {
|
||||||
Logger::notice('Could not parse the content');
|
Logger::notice('Could not parse the content');
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue