Fixing the Accepting of contact requests
This commit is contained in:
parent
6ae6a8a983
commit
defc89fa9a
1 changed files with 5 additions and 1 deletions
|
@ -370,6 +370,7 @@ class Processor
|
||||||
$cid = Contact::getIdForURL($activity['actor'], $uid);
|
$cid = Contact::getIdForURL($activity['actor'], $uid);
|
||||||
if (!empty($cid)) {
|
if (!empty($cid)) {
|
||||||
self::switchContact($cid);
|
self::switchContact($cid);
|
||||||
|
DBA::update('contact', ['hub-verify' => $activity['id']], ['id' => $cid]);
|
||||||
$contact = DBA::selectFirst('contact', [], ['id' => $cid, 'network' => Protocol::NATIVE_SUPPORT]);
|
$contact = DBA::selectFirst('contact', [], ['id' => $cid, 'network' => Protocol::NATIVE_SUPPORT]);
|
||||||
} else {
|
} else {
|
||||||
$contact = false;
|
$contact = false;
|
||||||
|
@ -387,7 +388,10 @@ class Processor
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
DBA::update('contact', ['hub-verify' => $activity['id']], ['id' => $cid]);
|
if (empty($contact)) {
|
||||||
|
DBA::update('contact', ['hub-verify' => $activity['id']], ['id' => $cid]);
|
||||||
|
}
|
||||||
|
|
||||||
Logger::log('Follow user ' . $uid . ' from contact ' . $cid . ' with id ' . $activity['id']);
|
Logger::log('Follow user ' . $uid . ' from contact ' . $cid . ' with id ' . $activity['id']);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue