diff --git src/bp-groups/bp-groups-classes.php src/bp-groups/bp-groups-classes.php
index b9017b9..fdd5c47 100644
|
|
|
class BP_Groups_Member { |
| 2493 | 2493 | * |
| 2494 | 2494 | * @param int $user_id ID of the user. |
| 2495 | 2495 | * @param int $group_id ID of the group. |
| 2496 | | * @param int|null ID of the membership if the user is an admin, |
| 2497 | | * otherwise null. |
| | 2496 | * @return int|false ID of the membership if the user is an admin, 0 if not an admin, |
| | 2497 | * false if no user_id is provided. |
| 2498 | 2498 | */ |
| 2499 | 2499 | public static function check_is_admin( $user_id, $group_id ) { |
| 2500 | 2500 | global $wpdb, $bp; |
| … |
… |
class BP_Groups_Member { |
| 2510 | 2510 | * |
| 2511 | 2511 | * @param int $user_id ID of the user. |
| 2512 | 2512 | * @param int $group_id ID of the group. |
| 2513 | | * @param int|null ID of the membership if the user is a mod, |
| 2514 | | * otherwise null. |
| | 2513 | * @return int|false ID of the membership if the user is a mod, 0 if not a mod, |
| | 2514 | * false if no user_id is provided. |
| 2515 | 2515 | */ |
| 2516 | 2516 | public static function check_is_mod( $user_id, $group_id ) { |
| 2517 | 2517 | global $wpdb, $bp; |
| … |
… |
class BP_Groups_Member { |
| 2527 | 2527 | * |
| 2528 | 2528 | * @param int $user_id ID of the user. |
| 2529 | 2529 | * @param int $group_id ID of the group. |
| 2530 | | * @param int|null ID of the membership if the user is a member, |
| 2531 | | * otherwise null. |
| | 2530 | * @return int|false ID of the membership if the user is a member, 0 if not a member, |
| | 2531 | * false if no user_id is provided. |
| 2532 | 2532 | */ |
| 2533 | 2533 | public static function check_is_member( $user_id, $group_id ) { |
| 2534 | 2534 | global $wpdb, $bp; |
diff --git src/bp-groups/bp-groups-functions.php src/bp-groups/bp-groups-functions.php
index ec3ec01..f533a4b 100644
|
|
|
function groups_avatar_upload_dir( $group_id = 0 ) { |
| 746 | 746 | * |
| 747 | 747 | * @param int $user_id ID of the user. |
| 748 | 748 | * @param int $group_id ID of the group. |
| 749 | | * @param int|null ID of the membership if the user is an admin, otherwise null. |
| | 749 | * @return int|false ID of the membership if the user is an admin, 0 if not an admin, |
| | 750 | * false if no user_id is provided. |
| 750 | 751 | */ |
| 751 | 752 | function groups_is_user_admin( $user_id, $group_id ) { |
| 752 | 753 | return BP_Groups_Member::check_is_admin( $user_id, $group_id ); |
| … |
… |
function groups_is_user_admin( $user_id, $group_id ) { |
| 757 | 758 | * |
| 758 | 759 | * @param int $user_id ID of the user. |
| 759 | 760 | * @param int $group_id ID of the group. |
| 760 | | * @param int|null ID of the membership if the user is a mod, otherwise null. |
| 761 | | */ |
| | 761 | * @return int|false ID of the membership if the user is a mod, 0 if not a mod, |
| | 762 | * false if no user_id is provided. |
| | 763 | */ |
| 762 | 764 | function groups_is_user_mod( $user_id, $group_id ) { |
| 763 | 765 | return BP_Groups_Member::check_is_mod( $user_id, $group_id ); |
| 764 | 766 | } |
| … |
… |
function groups_is_user_mod( $user_id, $group_id ) { |
| 768 | 770 | * |
| 769 | 771 | * @param int $user_id ID of the user. |
| 770 | 772 | * @param int $group_id ID of the group. |
| 771 | | * @param int|null ID of the membership if the user is a member, otherwise null. |
| | 773 | * @return int|false ID of the membership if the user is a member, 0 if not a member, |
| | 774 | * false if no user_id is provided. |
| 772 | 775 | */ |
| 773 | 776 | function groups_is_user_member( $user_id, $group_id ) { |
| 774 | 777 | return BP_Groups_Member::check_is_member( $user_id, $group_id ); |