if (ActivityPub::isRequest()) {
$user = DBA::selectFirst('user', ['uid'], ['nickname' => $which]);
if (DBA::isResult($user)) {
- $data = ActivityPub\Transmitter::profile($user['uid']);
+ $data = ActivityPub\Transmitter::getProfile($user['uid']);
echo json_encode($data);
header('Content-Type: application/activity+json');
exit();
* @param integer $uid User ID
* @return profile array
*/
- public static function profile($uid)
+ public static function getProfile($uid)
{
$condition = ['uid' => $uid, 'blocked' => false, 'account_expired' => false,
'account_removed' => false, 'verified' => true];
'id' => System::baseUrl() . '/activity/' . System::createGUID(),
'type' => 'Update',
'actor' => $owner['url'],
- 'object' => self::profile($uid),
+ 'object' => self::getProfile($uid),
'published' => DateTimeFormat::utcNow(DateTimeFormat::ATOM),
'to' => [$profile['followers']],
'cc' => []];