Opened 14 years ago
Closed 14 years ago
#4337 closed defect (bug) (fixed)
bp_blogs_record_existing_blogs() is not network-aware
| Reported by: | boonebgorges | Owned by: | boonebgorges |
|---|---|---|---|
| Priority: | normal | Milestone: | 1.7 |
| Component: | Blogs | Version: | 1.5.1 |
| Severity: | minor | Keywords: | has-patch |
| Cc: |
Description
When running a BP Multi Network setup, bp_blogs_record_existing_blogs() incorrectly records all blogs from the entire installation, regardless of site_id. This breaks multi-network setups, since all sites show on all site directories.
The answer is to change the blogs query to:
$blog_ids = $wpdb->get_col( $wpdb->prepare( "SELECT blog_id FROM {$wpdb->base_prefix}blogs WHERE mature = 0 AND spam = 0 AND deleted = 0 AND site_id = '{$wpdb->siteid}'" ) );
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)
This looks good to me.