[buddypress-trac] [BuddyPress Trac] #8750: Unread count not set for message threads

buddypress-trac noreply at wordpress.org
Sun Oct 9 22:24:54 UTC 2022


#8750: Unread count not set for message threads
--------------------------------------+---------------------
 Reporter:  sjregan                   |       Owner:  (none)
     Type:  defect (bug)              |      Status:  new
 Priority:  normal                    |   Milestone:  10.5.0
Component:  Messages                  |     Version:  10.4.0
 Severity:  normal                    |  Resolution:
 Keywords:  has-patch has-unit-tests  |
--------------------------------------+---------------------
Changes (by prbot):

 * keywords:  needs-patch => has-patch has-unit-tests


Comment:

 ''This ticket was mentioned in
 [https://github.com/buddypress/buddypress/pull/26 PR #26] on
 [https://github.com/buddypress/buddypress/ buddypress/buddypress] by
 [https://github.com/sjregan sjregan].''
 This fixes the unread_count property not always being set on message
 thread object when getting message threads for a user, particularly when
 'recipients_per_page' and 'recipients_page' are provided within arguments.



 * `BP_Tests_Messages_Template` has been updated to catch potential
 failure.
 * The `user_id` from arguments to
 `\BP_Messages_Thread::get_current_threads_for_user()` is now passed to
 `new BP_Messages_Thread()` for use when populating the thread.
 * `\BP_Messages_Thread::get_unread_count()` method added and used within
 `populate()`

 Trac ticket: https://buddypress.trac.wordpress.org/ticket/8750

-- 
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/8750#comment:3>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list