<?php
/**
 * Extend BuddyPress groups
 *
 * @package Nisje
 */

defined( 'ABSPATH' ) || die( 'Shame on you' );

/**
 * Fix bug in BuddyPress groups
 */
add_filter( 'bp_rest_groups_collection_params', function( $params ) {
	$params['meta']['items'] = [ 'type' => 'object' ];

	return $params;
} );
