bp_document_get_document_activity( $activity_id )
Return the document activity.
Description
Parameters
- $activity_id
-
(Required)
Return
(object|boolean) The document activity object or false.
Source
File: bp-document/bp-document-functions.php
function bp_document_get_document_activity( $activity_id ) {
if ( ! bp_is_active( 'activity' ) ) {
return false;
}
$result = bp_activity_get(
array(
'in' => $activity_id,
)
);
if ( empty( $result['activities'][0] ) ) {
return false;
}
/**
* Filters the document activity object being displayed.
*
* @param object $activity The document activity.
*
* @since BuddyBoss 1.4.0
*/
return apply_filters( 'bp_document_get_document_activity', $result['activities'][0] );
}
Changelog
| Version | Description |
|---|---|
| BuddyBoss 1.4.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.