BP_Groups_Group::delete_all_invites( int $group_id )
Delete all invitations to a given group.
Description
Parameters
- $group_id
-
(int) (Required) ID of the group whose invitations are being deleted.
Return
(int|null) Number of rows records deleted on success, null on failure.
Source
File: bp-groups/classes/class-bp-groups-group.php
public static function delete_all_invites( $group_id ) { global $wpdb; $bp = buddypress(); return $wpdb->query( $wpdb->prepare( "DELETE FROM {$bp->groups->table_name_members} WHERE group_id = %d AND invite_sent = 1", $group_id ) ); }
Changelog
Version | Description |
---|---|
BuddyPress 1.6.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.