Buddypress notifica...
 
Notifications
Clear all

wpForo 1.x.x [Closed] Buddypress notifications are not marked as read.

2 Posts
2 Users
0 Reactions
1,054 Views
Posts: 3
Topic starter
(@mrwhisk)
Active Member
Joined: 4 years ago

Hello.

File: wpforo/wpf-includes/integration/buddypress.php:684

In function wpforo_bp_buddypress_mark_notifications we have:

if ( isset($wp_error) && !is_wp_error($wp_error) ) {
$success = bp_notifications_mark_notifications_by_item_id( $user_id, $reply_id, 'community', 'wpforo_new_reply' );
do_action( 'wpforo_bp_notifications_handler', $success, $user_id, $reply_id, $action );
}

Since $wp_error is only defined in the event that there either !$result or !current_user_can( 'edit_user', $user_id ), the contents of the above if statement are never run. (If there isn't an error, then $wp_error is not set)

As a consequence, notifications are not cleared on action wpforo_mark_read.

Thankyou.

1 Reply
Alvina
Posts: 1867
Moderator
(@alvina)
Member
Joined: 5 years ago

Hi @mrwhisk,

Thank you for letting us know. I let developers known about the issue, and it will be fixed in the near feature.