diff --git src/bp-templates/bp-legacy/buddypress-functions.php src/bp-templates/bp-legacy/buddypress-functions.php
index dcd0254..65d5214 100644
|
|
function bp_legacy_theme_ajax_querystring( $query_string, $object ) { |
692 | 692 | |
693 | 693 | if ( bp_is_active( 'activity' ) ) { |
694 | 694 | $actions = bp_activity_get_actions_for_context(); |
695 | | foreach ( $actions as $action ) { |
696 | | if ( $action['key'] === $_BP_COOKIE['bp-' . $object . '-filter'] ) { |
697 | | $qs[] = 'action=' . $_BP_COOKIE['bp-' . $object . '-filter']; |
698 | | } |
| 695 | |
| 696 | // Accepts multiple actions in comma separated values (eg: 'friendship_accepted,friendship_created') |
| 697 | $action_filter = explode( ',', $_BP_COOKIE['bp-' . $object . '-filter'] ); |
| 698 | |
| 699 | // If All actions are available fot the context, include them into the query string |
| 700 | if ( ! array_diff( $action_filter, wp_list_pluck( $actions, 'key' ) ) ) { |
| 701 | $qs[] = 'action=' . join( ',', $action_filter ); |
699 | 702 | } |
700 | 703 | } |
701 | 704 | } |