bp_friends_mark_friendship_withdrawn_notifications_by_item_id( int $friendship_id, object $friendship )

Remove friend request notice when a member withdraws their friend request.

Description

Parameters

$friendship_id

(int) (Required) Friendship ID (not used).

$friendship

(object) (Required) Friendship Object.

Source

File: bp-friends/bp-friends-notifications.php

function bp_friends_mark_friendship_withdrawn_notifications_by_item_id( $friendship_id, $friendship ) {
	bp_notifications_delete_notifications_by_item_id( $friendship->friend_user_id, $friendship->initiator_user_id, buddypress()->friends->id, 'friendship_request' );
}

Changelog

Changelog
Version Description
BuddyPress 1.9.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.