bp_activity_clear_new_mentions( int $user_id )
Reset a user’s unread mentions list and count.
Description
Parameters
- $user_id
-
(Required) The id of the user whose unread mentions are being reset.
Source
File: bp-activity/bp-activity-functions.php
function bp_activity_clear_new_mentions( $user_id ) {
bp_delete_user_meta( $user_id, 'bp_new_mention_count' );
bp_delete_user_meta( $user_id, 'bp_new_mentions' );
/**
* Fires once mentions has been reset for a given user.
*
* @since BuddyPress 2.5.0
*
* @param int $user_id The id of the user whose unread mentions are being reset.
*/
do_action( 'bp_activity_clear_new_mentions', $user_id );
}
Changelog
| Version | Description |
|---|---|
| BuddyPress 1.5.0 | Introduced. |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.