Check $contact['id']
- see https://github.com/friendica/friendica/issues/6918#issuecomment-498043313
This commit is contained in:
parent
f5606fb211
commit
236c0dc248
|
@ -2157,7 +2157,8 @@ class Contact extends BaseObject
|
||||||
|
|
||||||
if (!empty($contact)) {
|
if (!empty($contact)) {
|
||||||
// Contact is blocked at user-level
|
// Contact is blocked at user-level
|
||||||
if (self::isBlockedByUser($contact['id'], $importer['id'])) {
|
if (!empty($contact['id']) && !empty($importer['id']) &&
|
||||||
|
self::isBlockedByUser($contact['id'], $importer['id'])) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -2216,11 +2216,10 @@ class DFRN
|
||||||
{
|
{
|
||||||
Logger::log("Process verb ".$item["verb"]." and object-type ".$item["object-type"]." for entrytype ".$entrytype, Logger::DEBUG);
|
Logger::log("Process verb ".$item["verb"]." and object-type ".$item["object-type"]." for entrytype ".$entrytype, Logger::DEBUG);
|
||||||
|
|
||||||
if (($entrytype == DFRN::TOP_LEVEL)) {
|
if (($entrytype == DFRN::TOP_LEVEL) && !empty($importer['id'])) {
|
||||||
// The filling of the the "contact" variable is done for legcy reasons
|
// The filling of the the "contact" variable is done for legcy reasons
|
||||||
// The functions below are partly used by ostatus.php as well - where we have this variable
|
// The functions below are partly used by ostatus.php as well - where we have this variable
|
||||||
$r = q("SELECT * FROM `contact` WHERE `id` = %d", intval($importer["id"]));
|
$contact = Contact::select([], ['id' => $importer['id']]);
|
||||||
$contact = $r[0];
|
|
||||||
|
|
||||||
// Big question: Do we need these functions? They were part of the "consume_feed" function.
|
// Big question: Do we need these functions? They were part of the "consume_feed" function.
|
||||||
// This function once was responsible for DFRN and OStatus.
|
// This function once was responsible for DFRN and OStatus.
|
||||||
|
|
Loading…
Reference in a new issue