bbp_filter_notifications_get_registered_components( array $component_names = array() )
Filter registered notifications components, and add ‘forums’ to the queried ‘component_name’ array.
Description Description
See also See also
Parameters Parameters
- $component_names
-
(Optional)
Default value: array()
Return Return
(array)
Source Source
File: includes/extend/buddypress/notifications.php
function bbp_filter_notifications_get_registered_components( $component_names = array() ) {
// Force $component_names to be an array
if ( ! is_array( $component_names ) ) {
$component_names = array();
}
// Add 'forums' component to registered components array
array_push( $component_names, bbp_get_component_name() );
// Return component's with 'forums' appended
return $component_names;
}
Changelog Changelog
| Version | Description |
|---|---|
| 2.6.0 | Introduced. |