BuddyPress - Version 2.6.1

Version Description

See: https://codex.buddypress.org/releases/version-2-6-1/

Download this release

Release Info

Developer dcavins
Plugin Icon 128x128 BuddyPress
Version 2.6.1
Comparing to
See all releases

Code changes from version 2.6.0 to 2.6.1

bp-activity/classes/class-bp-activity-activity.php CHANGED
@@ -613,6 +613,18 @@ class BP_Activity_Activity {
613
$activities = $wpdb->get_results( apply_filters( 'bp_activity_get_user_join_filter', "{$select_sql} {$from_sql} {$join_sql} {$where_sql} ORDER BY a.date_recorded {$sort}, a.id {$sort}", $select_sql, $from_sql, $where_sql, $sort, $pag_sql ) );
614
}
615
616
} else {
617
// Query first for activity IDs.
618
$activity_ids_sql = "{$select_sql} {$from_sql} {$join_sql} {$where_sql} ORDER BY a.date_recorded {$sort}, a.id {$sort}";
613
$activities = $wpdb->get_results( apply_filters( 'bp_activity_get_user_join_filter', "{$select_sql} {$from_sql} {$join_sql} {$where_sql} ORDER BY a.date_recorded {$sort}, a.id {$sort}", $select_sql, $from_sql, $where_sql, $sort, $pag_sql ) );
614
}
615
616
+ // Integer casting for legacy activity query.
617
+ foreach ( (array) $activities as $i => $ac ) {
618
+ $activities[ $i ]->id = (int) $ac->id;
619
+ $activities[ $i ]->item_id = (int) $ac->item_id;
620
+ $activities[ $i ]->secondary_item_id = (int) $ac->secondary_item_id;
621
+ $activities[ $i ]->user_id = (int) $ac->user_id;
622
+ $activities[ $i ]->hide_sitewide = (int) $ac->hide_sitewide;
623
+ $activities[ $i ]->mptt_left = (int) $ac->mptt_left;
624
+ $activities[ $i ]->mptt_right = (int) $ac->mptt_right;
625
+ $activities[ $i ]->is_spam = (int) $ac->is_spam;
626
+ }
627
+
628
} else {
629
// Query first for activity IDs.
630
$activity_ids_sql = "{$select_sql} {$from_sql} {$join_sql} {$where_sql} ORDER BY a.date_recorded {$sort}, a.id {$sort}";
bp-core/classes/class-bp-user-query.php CHANGED
@@ -797,10 +797,6 @@ class BP_User_Query {
797
798
$sql_clauses = $tax_query->get_sql( 'u', $this->uid_name );
799
800
- if ( $switched ) {
801
- restore_current_blog();
802
- }
803
-
804
$clause = '';
805
806
// The no_results clauses are the same between IN and NOT IN.
@@ -816,6 +812,10 @@ class BP_User_Query {
816
$clause = "u.{$this->uid_name} IN ( SELECT object_id FROM $wpdb->term_relationships WHERE {$matches[0]} )";
817
}
818
819
return $clause;
820
}
821
}
797
798
$sql_clauses = $tax_query->get_sql( 'u', $this->uid_name );
799
800
$clause = '';
801
802
// The no_results clauses are the same between IN and NOT IN.
812
$clause = "u.{$this->uid_name} IN ( SELECT object_id FROM $wpdb->term_relationships WHERE {$matches[0]} )";
813
}
814
815
+ if ( $switched ) {
816
+ restore_current_blog();
817
+ }
818
+
819
return $clause;
820
}
821
}
bp-groups/bp-groups-actions.php CHANGED
@@ -27,7 +27,7 @@ function bp_groups_register_group_types() {
27
*/
28
do_action( 'bp_groups_register_group_types' );
29
}
30
- add_action( 'bp_loaded', 'bp_groups_register_group_types', 8 );
31
32
/**
33
* Protect access to single groups.
27
*/
28
do_action( 'bp_groups_register_group_types' );
29
}
30
+ add_action( 'bp_init', 'bp_groups_register_group_types', 1 );
31
32
/**
33
* Protect access to single groups.
bp-groups/classes/class-bp-groups-group.php CHANGED
@@ -1644,10 +1644,6 @@ class BP_Groups_Group {
1644
1645
$sql_clauses = $tax_query->get_sql( 'g', 'id' );
1646
1647
- if ( $switched ) {
1648
- restore_current_blog();
1649
- }
1650
-
1651
$clause = '';
1652
1653
// The no_results clauses are the same between IN and NOT IN.
@@ -1663,6 +1659,10 @@ class BP_Groups_Group {
1663
$clause = " AND g.id IN ( SELECT object_id FROM $wpdb->term_relationships WHERE {$matches[0]} )";
1664
}
1665
1666
return $clause;
1667
}
1668
}
1644
1645
$sql_clauses = $tax_query->get_sql( 'g', 'id' );
1646
1647
$clause = '';
1648
1649
// The no_results clauses are the same between IN and NOT IN.
1659
$clause = " AND g.id IN ( SELECT object_id FROM $wpdb->term_relationships WHERE {$matches[0]} )";
1660
}
1661
1662
+ if ( $switched ) {
1663
+ restore_current_blog();
1664
+ }
1665
+
1666
return $clause;
1667
}
1668
}
bp-loader.php CHANGED
@@ -15,7 +15,7 @@
15
* Description: BuddyPress helps you build any type of community website using WordPress, with member profiles, activity streams, user groups, messaging, and more.
16
* Author: The BuddyPress Community
17
* Author URI: https://buddypress.org/
18
- * Version: 2.6.0
19
* Text Domain: buddypress
20
* Domain Path: /bp-languages/
21
* License: GPLv2 or later (license.txt)
@@ -330,7 +330,7 @@ class BuddyPress {
330
331
/** Versions **********************************************************/
332
333
- $this->version = '2.6.0';
334
$this->db_version = 10469;
335
336
/** Loading ***********************************************************/
@@ -617,6 +617,12 @@ class BuddyPress {
617
return;
618
}
619
620
require $path;
621
}
622
15
* Description: BuddyPress helps you build any type of community website using WordPress, with member profiles, activity streams, user groups, messaging, and more.
16
* Author: The BuddyPress Community
17
* Author URI: https://buddypress.org/
18
+ * Version: 2.6.1
19
* Text Domain: buddypress
20
* Domain Path: /bp-languages/
21
* License: GPLv2 or later (license.txt)
330
331
/** Versions **********************************************************/
332
333
+ $this->version = '2.6.1';
334
$this->db_version = 10469;
335
336
/** Loading ***********************************************************/
617
return;
618
}
619
620
+ // Sanity check 2 - Check if component is active before loading class.
621
+ // Skip if PHPUnit is running.
622
+ if ( 'core' !== $component && false === bp_is_active( $component ) && false === function_exists( 'tests_add_filter' ) ) {
623
+ return;
624
+ }
625
+
626
require $path;
627
}
628
bp-notifications/bp-notifications-functions.php CHANGED
@@ -254,7 +254,7 @@ function bp_notifications_get_notifications_for_user( $user_id, $format = 'strin
254
255
// Return an array of content strings.
256
} else {
257
- $content = call_user_func( $bp->{$component_name}->notification_callback, $component_action_name, $component_action_items[0]->item_id, $component_action_items[0]->secondary_item_id, $action_item_count, $component_action_items[0]->id );
258
$renderable[] = $content;
259
}
260
254
255
// Return an array of content strings.
256
} else {
257
+ $content = call_user_func( $bp->{$component_name}->notification_callback, $component_action_name, $component_action_items[0]->item_id, $component_action_items[0]->secondary_item_id, $action_item_count, 'string', $component_action_items[0]->id );
258
$renderable[] = $content;
259
}
260
bp-xprofile/classes/class-bp-xprofile-profiledata.php CHANGED
@@ -438,12 +438,13 @@ class BP_XProfile_ProfileData {
438
$user_ids = bp_displayed_user_id();
439
}
440
441
- $is_single = false;
442
if ( ! is_array( $user_ids ) ) {
443
- $user_ids = array( $user_ids );
444
- $is_single = true;
445
}
446
447
// Assemble uncached IDs.
448
$uncached_ids = array();
449
foreach ( $user_ids as $user_id ) {
@@ -494,7 +495,7 @@ class BP_XProfile_ProfileData {
494
}
495
496
// If a single ID was passed, just return the value.
497
- if ( $is_single ) {
498
return $data[0]->value;
499
500
// Otherwise return the whole array.
438
$user_ids = bp_displayed_user_id();
439
}
440
441
+ $return_single_result = false;
442
if ( ! is_array( $user_ids ) ) {
443
+ $return_single_result = true;
444
}
445
446
+ $user_ids = wp_parse_id_list( $user_ids );
447
+
448
// Assemble uncached IDs.
449
$uncached_ids = array();
450
foreach ( $user_ids as $user_id ) {
495
}
496
497
// If a single ID was passed, just return the value.
498
+ if ( $return_single_result ) {
499
return $data[0]->value;
500
501
// Otherwise return the whole array.
buddypress.pot CHANGED
@@ -2,9 +2,9 @@
2
# This file is distributed under the GPLv2 or later (license.txt).
3
msgid ""
4
msgstr ""
5
- "Project-Id-Version: BuddyPress 2.6.0\n"
6
"Report-Msgid-Bugs-To: https://buddypress.trac.wordpress.org\n"
7
- "POT-Creation-Date: 2016-06-22 23:43:34+00:00\n"
8
"MIME-Version: 1.0\n"
9
"Content-Type: text/plain; charset=utf-8\n"
10
"Content-Transfer-Encoding: 8bit\n"
@@ -5077,7 +5077,7 @@ msgstr ""
5077
msgid "Cheatin’ huh?"
5078
msgstr ""
5079
5080
- #: bp-loader.php:740
5081
msgid "BuddyPress Default"
5082
msgstr ""
5083
2
# This file is distributed under the GPLv2 or later (license.txt).
3
msgid ""
4
msgstr ""
5
+ "Project-Id-Version: BuddyPress 2.6.1\n"
6
"Report-Msgid-Bugs-To: https://buddypress.trac.wordpress.org\n"
7
+ "POT-Creation-Date: 2016-06-30 00:08:17+00:00\n"
8
"MIME-Version: 1.0\n"
9
"Content-Type: text/plain; charset=utf-8\n"
10
"Content-Transfer-Encoding: 8bit\n"
5077
msgid "Cheatin’ huh?"
5078
msgstr ""
5079
5080
+ #: bp-loader.php:746
5081
msgid "BuddyPress Default"
5082
msgstr ""
5083
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: johnjamesjacoby, DJPaul, boonebgorges, r-a-y, imath, mercime, tw21
3
Tags: social networking, activity, profiles, messaging, friends, groups, forums, notifications, settings, social, community, networks, networking
4
Requires at least: 4.1
5
Tested up to: 4.5.3
6
- Stable tag: 2.6.0
7
License: GPLv2 or later
8
License URI: https://www.gnu.org/licenses/gpl-2.0.html
9
@@ -118,143 +118,17 @@ Please consider helping translate BuddyPress at our <a href="https://translate.w
118
119
== Upgrade Notice ==
120
121
= 2.6.0 =
122
See: https://codex.buddypress.org/releases/version-2-6-0/
123
124
- = 2.5.3 =
125
- See: https://codex.buddypress.org/releases/version-2-5-3/
126
-
127
- = 2.5.2 =
128
- See: https://codex.buddypress.org/releases/version-2-5-2/
129
-
130
- = 2.5.1 =
131
- See: https://codex.buddypress.org/releases/version-2-5-1/
132
-
133
- = 2.5 =
134
- See: https://codex.buddypress.org/releases/version-2-5-0/
135
-
136
- = 2.4.3 =
137
- See: https://codex.buddypress.org/releases/version-2-4-3/
138
-
139
- = 2.4.2 =
140
- See: https://codex.buddypress.org/releases/version-2-4-2/
141
-
142
- = 2.4.1 =
143
- See: https://codex.buddypress.org/releases/version-2-4-1/
144
-
145
- = 2.4 =
146
- See: https://codex.buddypress.org/releases/version-2-4-0/
147
-
148
- = 2.3.5 =
149
- See: https://codex.buddypress.org/releases/version-2-3-5/
150
-
151
- = 2.3.4 =
152
- See: https://codex.buddypress.org/releases/version-2-3-4/
153
-
154
- = 2.3.3 =
155
- See: https://codex.buddypress.org/releases/version-2-3-3/
156
-
157
- = 2.3.2 =
158
- See: https://codex.buddypress.org/releases/version-2-3-2/
159
-
160
- = 2.3.1 =
161
- See: https://codex.buddypress.org/releases/version-2-3-1/
162
-
163
- = 2.3.0 =
164
- See: https://codex.buddypress.org/releases/version-2-3-0/
165
-
166
- = 2.2.3.1 =
167
- See: https://codex.buddypress.org/releases/version-2-2-3-1/
168
-
169
- = 2.2.3 =
170
- See: https://codex.buddypress.org/releases/version-2-2-3/
171
-
172
- = 2.2.2.1 =
173
- See: https://codex.buddypress.org/releases/version-2-2-2-1/
174
-
175
- = 2.2.2 =
176
- See: https://codex.buddypress.org/releases/version-2-2-2/
177
-
178
- = 2.2.1 =
179
- See: https://codex.buddypress.org/releases/version-2-2-1/
180
-
181
- = 2.2 =
182
- See: https://codex.buddypress.org/releases/version-2-2/
183
-
184
- = 2.1 =
185
- See: https://codex.buddypress.org/releases/version-2-1/
186
-
187
- = 2.0.3 =
188
- See: https://codex.buddypress.org/releases/version-2-0-3/
189
-
190
- = 2.0.2 =
191
- See: https://codex.buddypress.org/releases/version-2-0-2/
192
-
193
- = 2.0.1 =
194
- See: https://codex.buddypress.org/releases/version-2-0-1/
195
-
196
- = 2.0 =
197
- See: https://codex.buddypress.org/releases/version-2-0/
198
-
199
- = 1.9.2 =
200
- See: https://codex.buddypress.org/releases/version-1-9-2/
201
-
202
- = 1.9.1 =
203
- See: https://codex.buddypress.org/releases/version-1-9-1/
204
-
205
- = 1.9 =
206
- See: https://codex.buddypress.org/releases/version-1-9/
207
-
208
- = 1.8.1 =
209
- See: https://codex.buddypress.org/releases/version-1-8-1/
210
-
211
- = 1.8 =
212
- See: https://codex.buddypress.org/releases/version-1-8/
213
-
214
- = 1.7.3 =
215
- See: https://codex.buddypress.org/releases/version-1-7-3/
216
-
217
- = 1.7.2 =
218
- See: https://codex.buddypress.org/releases/version-1-7-2/
219
-
220
- = 1.7.1 =
221
- See: https://codex.buddypress.org/releases/version-1-7-1/
222
-
223
- = 1.7 =
224
- See: https://codex.buddypress.org/releases/version-1-7/
225
-
226
- = 1.6.5 =
227
- See: https://codex.buddypress.org/releases/version-1-6-5/
228
-
229
- = 1.6.4 =
230
- See: https://codex.buddypress.org/releases/version-1-6-4/
231
-
232
- = 1.6.3 =
233
- See: https://codex.buddypress.org/releases/version-1-6-3/
234
-
235
- = 1.6.2 =
236
- Compatibility with WordPress 3.5
237
-
238
- = 1.6.1 =
239
- Fixes 4 bugs
240
-
241
- = 1.6 =
242
- See: https://codex.buddypress.org/releases/version-1-6/
243
-
244
- = 1.5 =
245
- See: https://codex.buddypress.org/releases/version-1-5/
246
-
247
- = 1.2.9 =
248
- Compatibility with WordPress 3.2
249
-
250
- = 1.2.8 =
251
- Compatibility with WordPress 3.1
252
-
253
- = 1.2.7 =
254
- Fixes over 10 bugs.
255
-
256
== Changelog ==
257
258
= 2.6.0 =
259
See: https://codex.buddypress.org/releases/version-2-6-0/
260
3
Tags: social networking, activity, profiles, messaging, friends, groups, forums, notifications, settings, social, community, networks, networking
4
Requires at least: 4.1
5
Tested up to: 4.5.3
6
+ Stable tag: 2.6.1
7
License: GPLv2 or later
8
License URI: https://www.gnu.org/licenses/gpl-2.0.html
9
118
119
== Upgrade Notice ==
120
121
+ = 2.6.1 =
122
+ See: https://codex.buddypress.org/releases/version-2-6-1/
123
+
124
= 2.6.0 =
125
See: https://codex.buddypress.org/releases/version-2-6-0/
126
127
== Changelog ==
128
129
+ = 2.6.1 =
130
+ See: https://codex.buddypress.org/releases/version-2-6-1/
131
+
132
= 2.6.0 =
133
See: https://codex.buddypress.org/releases/version-2-6-0/
134