Skip to:
Content

BuddyPress.org

Opened 8 years ago

Closed 6 years ago

#7999 closed enhancement (fixed)

Support 'user_ids' argument in 'bp_has_members()`

Reported by: Mamaduka Owned by: boonebgorges
Priority: normal Milestone: 7.0.0
Component: Members Version: 1.7
Severity: normal Keywords:
Cc:

Description

This task requires BP_Core_Members_Template::construct() refactoring to use array-style arguments. Patch is provided in #3797.

Changes will also affect following classes/functions:

  • BP_Core_Members_Template
  • bp_core_get_users()

Attachments (1)

7999.diff (4.8 KB ) - added by Mamaduka 8 years ago.

Download all attachments as: .zip

Change History (8)

@Mamaduka
8 years ago

#1 @boonebgorges
8 years ago

  • Milestone Awaiting Review4.0

This looks like a good and easy improvement.

#2 follow-up: @boonebgorges
8 years ago

  • Milestone 4.0Up Next

Oh, I see now that we have to change the function signature of BP_Core_Members_Template first. This is more work that should be supported by tests. Let's do it next.

#3 in reply to: ↑ 2 @Mamaduka
8 years ago

Replying to boonebgorges:

Oh, I see now that we have to change the function signature of BP_Core_Members_Template first. This is more work that should be supported by tests. Let's do it next.

Thanks for Boone.

Should I add unit test for user_ids argument?

#4 @boonebgorges
8 years ago

Thanks, George! I'm more concerned about having tests for the changes in https://buddypress.trac.wordpress.org/attachment/ticket/3797/3797.core-members-template.2.diff. I see that you changed the way that the functions are used in the tests, which is a good start, but I'll want to have a closer look to make sure that we're properly converting deprecated arguments. This might mean one or two tests that pass the deprecated arguments (with @expectedDeprecated) that then check things like pagination, etc on the results.

#5 @imath
6 years ago

  • Milestone Up Next7.0.0

#6 @boonebgorges
6 years ago

In 12692:

Convert BP_Core_Members_Template to accept array of arguments.

This changeset also eliminates the use of extract() in
BP_Core_Members_Template::__construct().

Props Mamaduka.

See #3797, #7999.

#7 @boonebgorges
6 years ago

  • Owner set to boonebgorges
  • Resolutionfixed
  • Status newclosed

In 12693:

Add user_ids parameter to bp_has_members() and related functions.

Props Mamaduka.

Fixes #7999.

Note: See TracTickets for help on using tickets.