-
Notifications
You must be signed in to change notification settings - Fork 80
activitypub_get_wp_object_state
github-actions[bot] edited this page Aug 29, 2025
·
12 revisions
Allow plugins to get the federation state of a WordPress object.
/**
* Allow plugins to get the federation state of a WordPress object.
*
* @param Activitypub\false $state
* @param WP_Comment|\WP_Post $wp_object
* @return Activitypub\false The filtered value.
*/
function my_activitypub_get_wp_object_state_callback( Activitypub\false $state, WP_Comment|\WP_Post $wp_object ) {
// Your code here.
return $state;
}
add_filter( 'activitypub_get_wp_object_state', 'my_activitypub_get_wp_object_state_callback', 10, 2 );
-
Activitypub\false
$state
The state of the object. -
WP_Comment|\WP_Post
$wp_object
The WordPress object.
\apply_filters( 'activitypub_get_wp_object_state', false, $wp_object )
Follow @[email protected] for updates and news.