Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
03/13/2014 07:05:27 PM (13 years ago)
Author:
boonebgorges
Message:

Use WP Plugin API rather than call_user_func() to apply format_callback to activity actions

This allows plugin authors to modify or override default formatting callbacks
using the standard remove_filter() and add_filter() API functions.

Hat-tip to nacin for the idea

See #3856

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-groups/bp-groups-activity.php

    r8125 r8126  
    5555 * @since BuddyPress (2.0.0)
    5656 *
     57 * @param string $action Static activity action.
    5758 * @param object $activity Activity data object.
    5859 * @return string
    5960 */
    60 function bp_groups_format_activity_action_created_group( $activity ) {
     61function bp_groups_format_activity_action_created_group( $action, $activity ) {
    6162        $user_link = bp_core_get_userlink( $activity->user_id );
    6263
    … …  
    7778 * @since BuddyPress (2.0.0)
    7879 *
     80 * @param string $action Static activity action.
    7981 * @param object $activity Activity data object.
    8082 * @return string
    8183 */
    82 function bp_groups_format_activity_action_joined_group( $activity ) {
     84function bp_groups_format_activity_action_joined_group( $action, $activity ) {
    8385        $user_link = bp_core_get_userlink( $activity->user_id );
    8486
Note: See TracChangeset for help on using the changeset viewer.