BP_REST_Messages_Endpoint::get_thread_object( int $thread_id )

Get thread object.

Description

Parameters

$thread_id

(Required) Thread ID.

Return

(BP_Messages_Thread)

Source

File: bp-messages/classes/class-bp-rest-messages-endpoint.php

1614
1615
1616
1617
1618
1619
public function get_thread_object( $thread_id ) {
    add_filter( 'bp_messages_default_per_page', array( $this, 'bp_rest_messages_default_per_page' ) );
    $thread = new BP_Messages_Thread( $thread_id );
    remove_filter( 'bp_messages_default_per_page', array( $this, 'bp_rest_messages_default_per_page' ) );
    return $thread;
}

Changelog

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