BP_Blogs_Component::rest_api_init( array $controllers = array() )

Init the BP REST API.


Parameters Parameters

$controllers

(array) (Optional) See BP_Component::rest_api_init() for description.

Default value: array()


Source Source

File: bp-blogs/classes/class-bp-blogs-component.php

	public function rest_api_init( $controllers = array() ) {
		if ( is_multisite() ) {
			$controllers = array(
				'BP_REST_Blogs_Endpoint',
			);

			// Support to Blog Avatar.
			if ( bp_is_active( 'blogs', 'site-icon' ) ) {
				$controllers[] = 'BP_REST_Attachments_Blog_Avatar_Endpoint';
			}
		}

		parent::rest_api_init( $controllers );
	}


Top ↑

Changelog Changelog

Changelog
Version Description
6.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.