BP_Media::__construct( int|bool $id = false )

Constructor method.

Description

Parameters

$id

(Optional) The ID of a specific activity item.

Default value: false

Source

File: bp-media/classes/class-bp-media.php

	function __construct( $id = false ) {
		// Instantiate errors object.
		$this->errors = new WP_Error;

		if ( !empty( $id ) ) {
			$this->id = (int) $id;
			$this->populate();
		}
	}

Changelog

Changelog
Version Description
BuddyBoss 1.0.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.