BP_Document_Folder::prefetch_object_data( array $folders )
Pre-fetch data for objects associated with folders.
Description
folders are associated with users, and often with other BuddyPress data objects. Here, we pre-fetch data about these associated objects, so that inline lookups – done primarily when building action strings – do not result in excess database queries.
Parameters
- $folders
-
(Required) Array of document folders.
Return
(array) $folders Array of document folders.
Source
File: bp-document/classes/class-bp-document-folder.php
protected static function prefetch_object_data( $folders ) { /** * Filters inside prefetch_object_data method to aid in pre-fetching object data associated with folder. * * @param array $documents Array of document folders. * * @since BuddyBoss 1.4.0 */ return apply_filters( 'bp_document_folder_prefetch_object_data', $folders ); }
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.