-
Notifications
You must be signed in to change notification settings - Fork 81
activitypub_user_can_activitypub
github-actions[bot] edited this page Aug 18, 2025
·
8 revisions
Allow plugins to enable/disable users for ActivityPub.
/**
* Allow plugins to enable/disable users for ActivityPub.
*
* @param Activitypub\boolean $enabled
* @param int $user_id
* @return Activitypub\boolean The filtered value.
*/
function my_activitypub_user_can_activitypub_callback( Activitypub\boolean $enabled, int $user_id ) {
// Your code here.
return $enabled;
}
add_filter( 'activitypub_user_can_activitypub', 'my_activitypub_user_can_activitypub_callback', 10, 2 );
-
Activitypub\boolean
$enabled
True if the user is enabled, false otherwise. -
int
$user_id
The user ID.
apply_filters( 'activitypub_user_can_activitypub', $enabled, $user_id )
Follow @[email protected] for updates and news.