mirror of
https://github.com/Automattic/wordpress-activitypub
synced 2024-10-18 12:23:32 +00:00
Fire an action before a follower is removed (#937)
This commit is contained in:
parent
4fae81792b
commit
17f99cd36a
1 changed files with 9 additions and 0 deletions
|
@ -80,6 +80,15 @@ class Followers {
|
|||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Fires before a Follower is removed.
|
||||
*
|
||||
* @param \Activitypub\Model\Follower $follower The Follower object.
|
||||
* @param int $user_id The ID of the WordPress User.
|
||||
* @param string $actor The Actor URL.
|
||||
*/
|
||||
do_action( 'activitypub_followers_pre_remove_follower', $follower, $user_id, $actor );
|
||||
|
||||
return delete_post_meta( $follower->get__id(), 'activitypub_user_id', $user_id );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue