[buddypress-trac] [BuddyPress] #4851: Activity Loop args: scope 'favorites' overrides primary_id

buddypress-trac noreply at wordpress.org
Wed Feb 27 16:50:21 UTC 2013

#4851: Activity Loop args: scope 'favorites' overrides primary_id
 Reporter:  LucaRosaldi                          |       Owner:
     Type:  defect (bug)                         |      Status:  new
 Priority:  normal                               |   Milestone:  Future
Component:  Activity                             |  Release
 Severity:  normal                               |     Version:  1.7
 Keywords:  needs-patch dev-feedback needs-      |  Resolution:
  unit-tests                                     |
Changes (by boonebgorges):

 * keywords:  needs-patch dev-feedback => needs-patch dev-feedback needs-
 * milestone:  Awaiting Review => Future Release


 Yes, this is a side effect of the way `bp_has_activities()` work - if you
 are using a 'favorites' scope, the filters are bypassed.

 It'd be nice to fix this to work more gracefully at some point in the
 future, but it'd require massive refactoring of how activity filters work.

 In the meantime, here's a possible workaround: First, use
 `bp_activity_get_user_favorites()` to get an array of activity ids. Then,
 pass these ids to the `in` param of `bp_has_activities()` along with all
 of your other arguments.

Ticket URL: <https://buddypress.trac.wordpress.org/ticket/4851#comment:1>
BuddyPress <http://buddypress.org/>

More information about the buddypress-trac mailing list