2020-04-07 13:03:04 +00:00
|
|
|
<?php
|
2023-10-22 22:20:53 +00:00
|
|
|
$user = \Activitypub\Collection\Users::get_by_id( \get_the_author_meta( 'ID' ) );
|
2020-04-07 13:03:04 +00:00
|
|
|
|
|
|
|
/*
|
|
|
|
* Action triggerd prior to the ActivityPub profile being created and sent to the client
|
|
|
|
*/
|
2023-10-22 22:20:53 +00:00
|
|
|
\do_action( 'activitypub_json_author_pre', $user->get__id() );
|
2020-04-07 13:03:04 +00:00
|
|
|
|
|
|
|
\header( 'Content-Type: application/activity+json' );
|
2024-02-08 12:31:25 +00:00
|
|
|
echo $user->to_json(); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
|
2020-04-07 13:03:04 +00:00
|
|
|
|
|
|
|
/*
|
|
|
|
* Action triggerd after the ActivityPub profile has been created and sent to the client
|
|
|
|
*/
|
2023-10-22 22:20:53 +00:00
|
|
|
\do_action( 'activitypub_json_author_post', $user->get__id() );
|