OStatus contacts are now automatically converted to AP
This commit is contained in:
@@ -298,6 +298,9 @@ class Processor
|
||||
$item = ['author-id' => Contact::getIdForURL($activity['actor']),
|
||||
'author-link' => $activity['actor']];
|
||||
|
||||
// Ensure that the contact has got the right network type
|
||||
self::switchContact($item['author-id']);
|
||||
|
||||
Contact::addRelationship($owner, $contact, $item);
|
||||
$cid = Contact::getIdForURL($activity['actor'], $uid);
|
||||
if (empty($cid)) {
|
||||
|
||||
@@ -452,7 +452,7 @@ class Receiver
|
||||
* @param integer $uid User ID
|
||||
* @param string $url Profile URL
|
||||
*/
|
||||
private static function switchContact($cid, $uid, $url)
|
||||
public static function switchContact($cid, $uid, $url)
|
||||
{
|
||||
$profile = ActivityPub::probeProfile($url);
|
||||
if (empty($profile)) {
|
||||
|
||||
Reference in New Issue
Block a user