Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
11/08/2013 05:09:31 AM (11 years ago)
Author:
johnjamesjacoby
Message:

Introduce bp_core_mark_all_notifications_by_type() and replace bp_core_delete_all_notifications_by_type() usages. Ensures notifications are toggled as acknowledged rather than deleted. See #5148.

File:
1 edited

Legend:

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

    r7402 r7529  
    134134 * @since BuddyPress (1.5)
    135135 *
    136  * @global object $bp BuddyPress global settings
    137  * @uses bp_core_delete_notifications_by_type()
     136 * @uses bp_core_mark_all_notifications_by_type()
    138137 */
    139138function bp_activity_remove_screen_notifications() {
    140     global $bp;
    141 
    142     bp_core_delete_notifications_by_type( bp_loggedin_user_id(), $bp->activity->id, 'new_at_mention' );
     139    bp_core_mark_all_notifications_by_type( bp_loggedin_user_id(), buddypress()->activity->id, 'new_at_mention' );
    143140}
    144141add_action( 'bp_activity_screen_my_activity',               'bp_activity_remove_screen_notifications' );
Note: See TracChangeset for help on using the changeset viewer.