<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[BuddyPress][4965] trunk: Fix blog posts not showing in activity stream in non-multisites.</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg > ul, #logmsg > ol { margin-left: 0; margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://buddypress.trac.wordpress.org/changeset/4965">4965</a></dd>
<dt>Author</dt> <dd>djpaul</dd>
<dt>Date</dt> <dd>2011-08-11 20:44:20 +0000 (Thu, 11 Aug 2011)</dd>
</dl>

<h3>Log Message</h3>
<pre>Fix blog posts not showing in activity stream in non-multisites. Fixes <a href="http://buddypress.trac.wordpress.org/ticket/3445">#3445</a>, props boonebgorges and paulgibbs</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkbpblogsbpblogsfunctionsphp">trunk/bp-blogs/bp-blogs-functions.php</a></li>
<li><a href="#trunkbpblogsbpblogsloaderphp">trunk/bp-blogs/bp-blogs-loader.php</a></li>
<li><a href="#trunkbpcoreadminbpcoreadminphp">trunk/bp-core/admin/bp-core-admin.php</a></li>
<li><a href="#trunkbpcoreadminbpcoreupdatephp">trunk/bp-core/admin/bp-core-update.php</a></li>
<li><a href="#trunkbpcorebpcorefunctionsphp">trunk/bp-core/bp-core-functions.php</a></li>
<li><a href="#trunkbpcorebpcoreloaderphp">trunk/bp-core/bp-core-loader.php</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkbpblogsbpblogsfunctionsphp"></a>
<div class="modfile"><h4>Modified: trunk/bp-blogs/bp-blogs-functions.php (4964 => 4965)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-blogs/bp-blogs-functions.php        2011-08-10 13:30:58 UTC (rev 4964)
+++ trunk/bp-blogs/bp-blogs-functions.php        2011-08-11 20:44:20 UTC (rev 4965)
</span><span class="lines">@@ -49,14 +49,17 @@
</span><span class="cx">         // Truncate user blogs table and re-record.
</span><span class="cx">         $wpdb-&gt;query( &quot;TRUNCATE TABLE {$bp-&gt;blogs-&gt;table_name}&quot; );
</span><span class="cx"> 
</span><del>-        $blog_ids = $wpdb-&gt;get_col( $wpdb-&gt;prepare( &quot;SELECT blog_id FROM {$wpdb-&gt;base_prefix}blogs WHERE mature = 0 AND spam = 0 AND deleted = 0&quot; ) );
</del><ins>+        if ( is_multisite() )
+                $blog_ids = $wpdb-&gt;get_col( $wpdb-&gt;prepare( &quot;SELECT blog_id FROM {$wpdb-&gt;base_prefix}blogs WHERE mature = 0 AND spam = 0 AND deleted = 0&quot; ) );
+        else
+                $blog_ids = 1;
</ins><span class="cx"> 
</span><span class="cx">         if ( $blog_ids ) {
</span><span class="cx">                 foreach( (array)$blog_ids as $blog_id ) {
</span><span class="cx">                         $users                 = get_users( array( 'blog_id' =&gt; $blog_id ) );
</span><span class="cx">                         $subscribers         = get_users( array( 'blog_id' =&gt; $blog_id, 'role' =&gt; 'subscriber' ) );
</span><span class="cx"> 
</span><del>-                        if ( $users ) {
</del><ins>+                        if ( !empty( $users ) ) {
</ins><span class="cx">                                 foreach ( (array)$users as $user ) {
</span><span class="cx">                                         // Don't record blogs for subscribers
</span><span class="cx">                                         if ( !in_array( $user, $subscribers ) )
</span><span class="lines">@@ -460,7 +463,7 @@
</span><span class="cx"> function bp_blogs_delete_blogmeta( $blog_id, $meta_key = false, $meta_value = false ) {
</span><span class="cx">         global $wpdb, $bp;
</span><span class="cx"> 
</span><del>-        if ( !is_numeric( $blog_id ) || !is_multisite() )
</del><ins>+        if ( !is_numeric( $blog_id ) )
</ins><span class="cx">                 return false;
</span><span class="cx"> 
</span><span class="cx">         $meta_key = preg_replace('|[^a-z0-9_]|i', '', $meta_key);
</span><span class="lines">@@ -487,7 +490,7 @@
</span><span class="cx"> 
</span><span class="cx">         $blog_id = (int) $blog_id;
</span><span class="cx"> 
</span><del>-        if ( !$blog_id || !is_multisite() )
</del><ins>+        if ( !$blog_id )
</ins><span class="cx">                 return false;
</span><span class="cx"> 
</span><span class="cx">         if ( !empty($meta_key) ) {
</span><span class="lines">@@ -519,7 +522,7 @@
</span><span class="cx"> function bp_blogs_update_blogmeta( $blog_id, $meta_key, $meta_value ) {
</span><span class="cx">         global $wpdb, $bp;
</span><span class="cx"> 
</span><del>-        if ( !is_numeric( $blog_id ) || !is_multisite() )
</del><ins>+        if ( !is_numeric( $blog_id ) )
</ins><span class="cx">                 return false;
</span><span class="cx"> 
</span><span class="cx">         $meta_key = preg_replace( '|[^a-z0-9_]|i', '', $meta_key );
</span></span></pre></div>
<a id="trunkbpblogsbpblogsloaderphp"></a>
<div class="modfile"><h4>Modified: trunk/bp-blogs/bp-blogs-loader.php (4964 => 4965)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-blogs/bp-blogs-loader.php        2011-08-10 13:30:58 UTC (rev 4964)
+++ trunk/bp-blogs/bp-blogs-loader.php        2011-08-11 20:44:20 UTC (rev 4965)
</span><span class="lines">@@ -53,7 +53,7 @@
</span><span class="cx">                         'path'                  =&gt; BP_PLUGIN_DIR,
</span><span class="cx">                         'slug'                  =&gt; BP_BLOGS_SLUG,
</span><span class="cx">                         'root_slug'             =&gt; isset( $bp-&gt;pages-&gt;blogs-&gt;slug ) ? $bp-&gt;pages-&gt;blogs-&gt;slug : BP_BLOGS_SLUG,
</span><del>-                        'has_directory'         =&gt; true,
</del><ins>+                        'has_directory'         =&gt; is_multisite(), // Non-multisite installs don't need a top-level Sites directory, since there's only one site
</ins><span class="cx">                         'notification_callback' =&gt; 'bp_blogs_format_notifications',
</span><span class="cx">                         'search_string'         =&gt; __( 'Search sites...', 'buddypress' ),
</span><span class="cx">                         'autocomplete_all'      =&gt; defined( 'BP_MESSAGES_AUTOCOMPLETE_ALL' ),
</span></span></pre></div>
<a id="trunkbpcoreadminbpcoreadminphp"></a>
<div class="modfile"><h4>Modified: trunk/bp-core/admin/bp-core-admin.php (4964 => 4965)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-core/admin/bp-core-admin.php        2011-08-10 13:30:58 UTC (rev 4964)
+++ trunk/bp-core/admin/bp-core-admin.php        2011-08-11 20:44:20 UTC (rev 4965)
</span><span class="lines">@@ -13,37 +13,6 @@
</span><span class="cx"> add_action( 'in_plugin_update_message-buddypress/bp-loader.php', 'bp_core_update_message' );
</span><span class="cx"> 
</span><span class="cx"> /**
</span><del>- * Renders the main admin panel.
- *
- * @package BuddyPress Core
- * @since {@internal Unknown}}
- */
-function bp_core_admin_dashboard() {
-        $base_url = bp_get_admin_url( 'admin.php' );
-        $action   = add_query_arg( array( 'page' =&gt; 'bp-general-settings' ), $base_url );
-        ?&gt;
-
-        &lt;div class=&quot;wrap&quot; id=&quot;bp-admin&quot;&gt;
-
-                &lt;div id=&quot;bp-admin-header&quot;&gt;
-                        &lt;h3&gt;&lt;?php _e( 'BuddyPress', 'buddypress' ); ?&gt;&lt;/h3&gt;
-                        &lt;h2&gt;&lt;?php _e( 'Dashboard',  'buddypress' ); ?&gt;&lt;/h2&gt;
-                &lt;/div&gt;
-
-                &lt;?php do_action( 'bp_admin_notices' ); ?&gt;
-
-                &lt;form action=&quot;&lt;?php echo $action ?&gt;&quot; method=&quot;post&quot; id=&quot;bp-admin-form&quot;&gt;
-                        &lt;div id=&quot;bp-admin-content&quot;&gt;
-                                &lt;p&gt;[TODO: All sorts of awesome things will go here. Latest plugins and themes, stats, version check, support topics, news, tips]&lt;/p&gt;
-                        &lt;/div&gt;
-                &lt;/form&gt;
-
-        &lt;/div&gt;
-
-&lt;?php
-}
-
-/**
</del><span class="cx">  * Renders the Settings admin panel.
</span><span class="cx">  *
</span><span class="cx">  * @package BuddyPress Core
</span><span class="lines">@@ -347,7 +316,7 @@
</span><span class="cx">                         'title'       =&gt; __( 'Account Settings', 'buddypress' ),
</span><span class="cx">                         'description' =&gt; __( 'Allow your users to modify their account and notification settings directly from within their profiles.', 'buddypress' )
</span><span class="cx">                 ),
</span><del>-                'friends' =&gt; array(
</del><ins>+                'friends'  =&gt; array(
</ins><span class="cx">                         'title'       =&gt; __( 'Friend Connections', 'buddypress' ),
</span><span class="cx">                         'description' =&gt; __( 'Let your users make connections so they can track the activity of others and focus on the people they care about the most.', 'buddypress' )
</span><span class="cx">                 ),
</span><span class="lines">@@ -359,22 +328,22 @@
</span><span class="cx">                         'title'       =&gt; __( 'Activity Streams', 'buddypress' ),
</span><span class="cx">                         'description' =&gt; __( 'Global, personal, and group activity streams with threaded commenting, direct posting, favoriting and @mentions, all with full RSS feed and email notification support.', 'buddypress' )
</span><span class="cx">                 ),
</span><del>-                'groups' =&gt; array(
</del><ins>+                'groups'   =&gt; array(
</ins><span class="cx">                         'title'       =&gt; __( 'User Groups', 'buddypress' ),
</span><span class="cx">                         'description' =&gt; __( 'Groups allow your users to organize themselves into specific public, private or hidden sections with separate activity streams and member listings.', 'buddypress' )
</span><span class="cx">                 ),
</span><del>-                'forums' =&gt; array(
</del><ins>+                'forums'   =&gt; array(
</ins><span class="cx">                         'title'       =&gt; __( 'Discussion Forums', 'buddypress' ),
</span><span class="cx">                         'description' =&gt; __( 'Full-powered discussion forums built directly into groups allow for more conventional in-depth conversations. NOTE: This will require an extra (but easy) setup step.', 'buddypress' )
</span><ins>+                ),
+                'blogs'    =&gt; array(
+                        'title'       =&gt; __( 'Site Tracking', 'buddypress' ),
+                        'description' =&gt; __( 'Make BuddyPress aware of new posts and new comments from your site.', 'buddypress' )
</ins><span class="cx">                 )
</span><span class="cx">         ) );
</span><span class="cx"> 
</span><del>-        if ( is_multisite() ) {
-                $optional_components['blogs'] = array(
-                        'title'       =&gt; __( 'Site Tracking', 'buddypress' ),
-                        'description' =&gt; __( 'Track new sites, new posts and new comments across your entire network.', 'buddypress' )
-                );
-        }
</del><ins>+        if ( is_multisite() ) 
+                $optional_components['blogs']['description'] = __( 'Make BuddyPress aware of new sites, new posts and new comments from across your entire network.', 'buddypress' ); 
</ins><span class="cx"> 
</span><span class="cx">         // Required components
</span><span class="cx">         $required_components = apply_filters( 'bp_admin_required_components', array(
</span></span></pre></div>
<a id="trunkbpcoreadminbpcoreupdatephp"></a>
<div class="modfile"><h4>Modified: trunk/bp-core/admin/bp-core-update.php (4964 => 4965)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-core/admin/bp-core-update.php        2011-08-10 13:30:58 UTC (rev 4964)
+++ trunk/bp-core/admin/bp-core-update.php        2011-08-11 20:44:20 UTC (rev 4965)
</span><span class="lines">@@ -301,7 +301,7 @@
</span><span class="cx">                         &lt;tr valign=&quot;top&quot;&gt;
</span><span class="cx">                                 &lt;th scope=&quot;row&quot;&gt;
</span><span class="cx">                                         &lt;h5&gt;&lt;?php _e( 'Sites', 'buddypress' ); ?&gt;&lt;/h5&gt;
</span><del>-                                        &lt;p&gt;&lt;?php _e( 'Displays individual groups as well as a directory of groups.', 'buddypress' ); ?&gt;&lt;/p&gt;
</del><ins>+                                        &lt;p&gt;&lt;?php _e( 'Displays a directory of the sites in your network.', 'buddypress' ); ?&gt;&lt;/p&gt;
</ins><span class="cx">                                 &lt;/th&gt;
</span><span class="cx">                                 &lt;td&gt;
</span><span class="cx">                                         &lt;p&gt;&lt;input type=&quot;radio&quot; name=&quot;bp_pages[blogs]&quot; checked=&quot;checked&quot; value=&quot;&lt;?php echo $blogs_slug; ?&gt;&quot; /&gt; &lt;?php _e( 'Automatically create a page at:', 'buddypress' ); ?&gt; &lt;?php echo site_url( $blogs_slug ); ?&gt;/&lt;/p&gt;
</span><span class="lines">@@ -311,7 +311,7 @@
</span><span class="cx"> 
</span><span class="cx">                 &lt;/table&gt;
</span><span class="cx"> 
</span><del>-                &lt;p&gt;&lt;?php _e( 'Would you like to enable site tracking, which tracks activity across all of your network?', 'buddypress' ); ?&gt;&lt;/p&gt;
</del><ins>+                &lt;p&gt;&lt;?php _e( 'Would you like to enable site tracking, which tracks blog posts and comments from across your network?', 'buddypress' ); ?&gt;&lt;/p&gt;
</ins><span class="cx"> 
</span><span class="cx">                 &lt;div class=&quot;left-col&quot;&gt;
</span><span class="cx"> 
</span><span class="lines">@@ -427,7 +427,7 @@
</span><span class="cx"> 
</span><span class="cx">                         &lt;tr valign=&quot;top&quot;&gt;
</span><span class="cx">                                 &lt;th scope=&quot;row&quot;&gt;
</span><del>-                                        &lt;h5&gt;&lt;?php _e( 'Members', 'buddypres' ); ?&gt;&lt;/h5&gt;
</del><ins>+                                        &lt;h5&gt;&lt;?php _e( 'Members', 'buddypress' ); ?&gt;&lt;/h5&gt;
</ins><span class="cx">                                         &lt;p&gt;&lt;?php _e( 'Displays member profiles, and a directory of all site members.', 'buddypress' ); ?&gt;&lt;/p&gt;
</span><span class="cx">                                 &lt;/th&gt;
</span><span class="cx">                                 &lt;td&gt;
</span><span class="lines">@@ -471,7 +471,7 @@
</span><span class="cx">                                 &lt;tr valign=&quot;top&quot;&gt;
</span><span class="cx">                                         &lt;th scope=&quot;row&quot;&gt;
</span><span class="cx">                                                 &lt;h5&gt;&lt;?php _e( 'Forums', 'buddypress' ); ?&gt;&lt;/h5&gt;
</span><del>-                                                &lt;p&gt;&lt;?php _e( 'Displays individual groups as well as a directory of groups.', 'buddypress' ); ?&gt;&lt;/p&gt;
</del><ins>+                                                &lt;p&gt;&lt;?php _e( 'Displays a directory of public forum topics.', 'buddypress' ); ?&gt;&lt;/p&gt;
</ins><span class="cx">                                         &lt;/th&gt;
</span><span class="cx">                                         &lt;td&gt;
</span><span class="cx">                                                 &lt;p&gt;&lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;bp_pages[forums]&quot; &lt;?php checked( empty( $existing_pages['forums'] ) ); ?&gt;  value=&quot;&lt;?php echo $forums_slug; ?&gt;&quot; /&gt; &lt;?php _e( 'Automatically create a page at:', 'buddypress' ); ?&gt; &lt;?php echo home_url( $forums_slug ); ?&gt;/&lt;/label&gt;&lt;/p&gt;
</span><span class="lines">@@ -481,12 +481,13 @@
</span><span class="cx"> 
</span><span class="cx">                         &lt;?php endif; ?&gt;
</span><span class="cx"> 
</span><ins>+                        &lt;?php /* The Blogs component only needs a directory page when Multisite is enabled */ ?&gt;
</ins><span class="cx">                         &lt;?php if ( is_multisite() &amp;&amp; isset( $active_components['blogs'] ) ) : ?&gt;
</span><span class="cx"> 
</span><span class="cx">                                 &lt;tr valign=&quot;top&quot;&gt;
</span><span class="cx">                                         &lt;th scope=&quot;row&quot;&gt;
</span><span class="cx">                                                 &lt;h5&gt;&lt;?php _e( 'Sites', 'buddypress' ); ?&gt;&lt;/h5&gt;
</span><del>-                                                &lt;p&gt;&lt;?php _e( 'Displays individual groups as well as a directory of groups.', 'buddypress' ); ?&gt;&lt;/p&gt;
</del><ins>+                                                &lt;p&gt;&lt;?php _e( 'Displays a directory of the sites in your network.', 'buddypress' ); ?&gt;&lt;/p&gt;
</ins><span class="cx">                                         &lt;/th&gt;
</span><span class="cx">                                         &lt;td&gt;
</span><span class="cx">                                                 &lt;p&gt;&lt;label&gt;&lt;input type=&quot;radio&quot; name=&quot;bp_pages[blogs]&quot; &lt;?php checked( empty( $existing_pages['blogs'] ) ); ?&gt;  value=&quot;&lt;?php echo $blogs_slug; ?&gt;&quot; /&gt; &lt;?php _e( 'Automatically create a page at:', 'buddypress' ); ?&gt; &lt;?php echo home_url( $blogs_slug ); ?&gt;/&lt;/label&gt;&lt;/p&gt;
</span><span class="lines">@@ -1022,6 +1023,7 @@
</span><span class="cx">                         // Load BP and hook the admin menu, so that the redirect is successful
</span><span class="cx">                         if ( !function_exists( 'bp_core_update_message' ) )
</span><span class="cx">                                 require( WP_PLUGIN_DIR . '/buddypress/bp-core/admin/bp-core-admin.php' );
</span><ins>+
</ins><span class="cx">                         bp_core_add_admin_menu();
</span><span class="cx"> 
</span><span class="cx">                         // Redirect to the BuddyPress dashboard
</span><span class="lines">@@ -1109,8 +1111,8 @@
</span><span class="cx">         if ( !empty( $active_components['xprofile'] ) )
</span><span class="cx">                 bp_core_install_extended_profiles();
</span><span class="cx"> 
</span><del>-        // Only install blog tables if this is a multisite installation
-        if ( is_multisite() &amp;&amp; !empty( $active_components['blogs'] ) )
</del><ins>+        // Blog tracking
+        if ( !empty( $active_components['blogs'] ) )
</ins><span class="cx">                 bp_core_install_blog_tracking();
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -1136,7 +1138,7 @@
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="cx">         // On first installation - record all existing blogs in the system.
</span><del>-        if ( !(int)$bp-&gt;site_options['bp-blogs-first-install'] &amp;&amp; is_multisite() ) {
</del><ins>+        if ( !(int)$bp-&gt;site_options['bp-blogs-first-install'] ) {
</ins><span class="cx">                 bp_blogs_record_existing_blogs();
</span><span class="cx">                 bp_update_option( 'bp-blogs-first-install', 1 );
</span><span class="cx">         }
</span></span></pre></div>
<a id="trunkbpcorebpcorefunctionsphp"></a>
<div class="modfile"><h4>Modified: trunk/bp-core/bp-core-functions.php (4964 => 4965)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-core/bp-core-functions.php        2011-08-10 13:30:58 UTC (rev 4964)
+++ trunk/bp-core/bp-core-functions.php        2011-08-11 20:44:20 UTC (rev 4965)
</span><span class="lines">@@ -352,7 +352,7 @@
</span><span class="cx">          * wizard because of the order which the components are loaded. We check for multisite here
</span><span class="cx">          * on the off chance that someone has activated the blogs component and then disabled MS
</span><span class="cx">          */
</span><del>-        if ( is_multisite() &amp;&amp; bp_is_active( 'blogs' ) ) {
</del><ins>+        if ( bp_is_active( 'blogs' ) ) {
</ins><span class="cx">                 $count = $wpdb-&gt;get_var( $wpdb-&gt;prepare( &quot;SELECT COUNT(*) FROM {$bp-&gt;blogs-&gt;table_name}&quot; ) );
</span><span class="cx"> 
</span><span class="cx">                 if ( !$count )
</span></span></pre></div>
<a id="trunkbpcorebpcoreloaderphp"></a>
<div class="modfile"><h4>Modified: trunk/bp-core/bp-core-loader.php (4964 => 4965)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/bp-core/bp-core-loader.php        2011-08-10 13:30:58 UTC (rev 4964)
+++ trunk/bp-core/bp-core-loader.php        2011-08-11 20:44:20 UTC (rev 4965)
</span><span class="lines">@@ -57,16 +57,10 @@
</span><span class="cx">                 /** Components ********************************************************/
</span><span class="cx"> 
</span><span class="cx">                 // Set the included and optional components.
</span><del>-                $bp-&gt;optional_components = array( 'activity', 'forums', 'friends', 'groups', 'messages', 'settings', 'xprofile' );
</del><ins>+                $bp-&gt;optional_components = apply_filters( 'bp_optional_components', array( 'activity', 'blogs', 'forums', 'friends', 'groups', 'messages', 'settings', 'xprofile' ) );
</ins><span class="cx"> 
</span><del>-                // Blogs component only available for multisite
-                if ( is_multisite() )
-                        $bp-&gt;optional_components[] = 'blogs';
-
-                $bp-&gt;optional_components    = apply_filters( 'bp_optional_components', $bp-&gt;optional_components );
-
</del><span class="cx">                 // Set the required components
</span><del>-                $bp-&gt;required_components    = apply_filters( 'bp_required_components', array( 'members' ) );
</del><ins>+                $bp-&gt;required_components = apply_filters( 'bp_required_components', array( 'members' ) );
</ins><span class="cx"> 
</span><span class="cx">                 // Get a list of activated components
</span><span class="cx">                 if ( $active_components = bp_get_option( 'bp-active-components' ) ) {
</span></span></pre>
</div>
</div>

</body>
</html>