Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
06/06/2017 05:46:21 PM (7 years ago)
Author:
dcavins
Message:

Show displayed user's messages on messages screens.

When a site administrator visits another user’s messages, she is shown
her own messages because the display logic for messages refers to the
logged-in user rather than the displayed user. This changeset updates
the logic to allow the site admin to view and interact with another
user’s messages.

Fixes #7096.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-messages/bp-messages-notifications.php

    r11022 r11578  
    172172    global $thread_template;
    173173
     174    /*
     175     * Only run on the logged-in user's profile.
     176     * If an admin visits a thread, it shouldn't change the read status.
     177     */
     178    if ( ! bp_is_my_profile() ) {
     179        return;
     180    }
     181
    174182    // Get unread PM notifications for the user.
    175183    $new_pm_notifications = BP_Notifications_Notification::get( array(
Note: See TracChangeset for help on using the changeset viewer.