Skip to content

pre_get_remote_metadata_by_actor

github-actions[bot] edited this page Sep 10, 2025 · 9 revisions

Filters the metadata before it is retrieved from a remote actor.

Passing a non-false value will effectively short-circuit the remote request, returning that value instead.

Default false to continue with the remote request.

Auto-generated Example

/**
 * Filters the metadata before it is retrieved from a remote actor.
 * 
 * Passing a non-false value will effectively short-circuit the remote request,
 * returning that value instead.
 * 
 * Default false to continue with the remote request.
 *
 * @param Activitypub\mixed $pre 
 * @param string            $actor 
 * @return Activitypub\mixed The filtered value.
 */
function my_pre_get_remote_metadata_by_actor_callback( Activitypub\mixed $pre, string $actor ) {
    // Your code here.
    return $pre;
}
add_filter( 'pre_get_remote_metadata_by_actor', 'my_pre_get_remote_metadata_by_actor_callback', 10, 2 );

Parameters

  • Activitypub\mixed $pre The value to return instead of the remote metadata.
  • string $actor The actor URL.

Files

apply_filters( 'pre_get_remote_metadata_by_actor', false, $actor )

← All Hooks

Users

Developers

Clone this wiki locally