Opened 10 years ago
Closed 10 years ago
#7208 closed defect (bug) (fixed)
`bp_get_user_groups()` performance issues
| Reported by: | boonebgorges | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | 2.7 |
| Component: | Groups | Version: | |
| Severity: | normal | Keywords: | |
| Cc: |
Description
Working with bp_get_user_groups() on a site where a user is a member of many hundreds of groups, I've noted some performance issues.
First: when looping through groups and casting keys to integer or boolean, the key whitelist is being regenerated each time through the loop. This only needs to be done once.
Second: wp_list_filter() is slow. I wonder if there's a way to filter these items earlier.
Change History (3)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
In 10977: