- Timestamp:
- 03/31/2020 11:33:35 AM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-groups/classes/class-bp-groups-component.php
r12590 r12607 937 937 * 938 938 * @since 5.0.0 939 * @since 6.0.0 Adds the Group Cover REST endpoint. 939 940 * 940 941 * @param array $controllers Optional. See BP_Component::rest_api_init() for … … 942 943 */ 943 944 public function rest_api_init( $controllers = array() ) { 944 parent::rest_api_init(array(945 $controllers = array( 945 946 'BP_REST_Groups_Endpoint', 946 947 'BP_REST_Group_Membership_Endpoint', … … 948 949 'BP_REST_Group_Membership_Request_Endpoint', 949 950 'BP_REST_Attachments_Group_Avatar_Endpoint', 950 ) ); 951 ); 952 953 // Support to Group Cover. 954 if ( bp_is_active( 'groups', 'cover_image' ) ) { 955 $controllers[] = 'BP_REST_Attachments_Group_Cover_Endpoint'; 956 } 957 958 parent::rest_api_init( $controllers ); 951 959 } 952 960
Note: See TracChangeset
for help on using the changeset viewer.