Skip to:
Content

BuddyPress.org

Changeset 5335


Ignore:
Timestamp:
11/15/2011 03:05:48 PM (13 years ago)
Author:
boonebgorges
Message:

Look in root blog when pulling up root options en masse in bp_core_get_root_options(). Fixes #3750

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/1.5/bp-core/bp-core-functions.php

    r5239 r5335  
    10011001    $root_blog_option_keys  = array_keys( $root_blog_options );
    10021002    $blog_options_keys      = "'" . join( "', '", (array) $root_blog_option_keys ) . "'";
    1003     $blog_options_query     = $wpdb->prepare( "SELECT option_name AS name, option_value AS value FROM {$wpdb->options} WHERE option_name IN ( {$blog_options_keys} )" );
     1003    $blog_options_table = bp_is_multiblog_mode() ? $wpdb->options : $wpdb->get_blog_prefix( bp_get_root_blog_id() ) . 'options';
     1004
     1005    $blog_options_query     = $wpdb->prepare( "SELECT option_name AS name, option_value AS value FROM {$blog_options_table} WHERE option_name IN ( {$blog_options_keys} )" );
    10041006    $root_blog_options_meta = $wpdb->get_results( $blog_options_query );
    10051007
Note: See TracChangeset for help on using the changeset viewer.