Opened 12 years ago
Closed 12 years ago
#4337 closed defect (bug) (fixed)
bp_blogs_record_existing_blogs() is not network-aware
Reported by: | boonebgorges | Owned by: | boonebgorges |
---|---|---|---|
Milestone: | 1.7 | Priority: | normal |
Severity: | minor | Version: | 1.5.1 |
Component: | Blogs | 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.
This looks good to me.