Changeset 8818
- Timestamp:
- 08/12/2014 09:31:40 PM (10 years ago)
- Location:
- trunk/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-activity/bp-activity-classes.php
r8787 r8818 334 334 $where_conditions = array(); 335 335 336 // Excluded types 337 $excluded_types = array(); 338 336 339 // Spam 337 340 if ( 'ham_only' == $spam ) … … 392 395 // the activity. 393 396 if ( false === $display_comments || 'threaded' === $display_comments ) { 394 $ where_conditions[] = "a.type != 'activity_comment'";397 $excluded_types[] = 'activity_comment'; 395 398 } 396 399 … … 398 401 // been explicitly set 399 402 if ( empty( $filter['object'] ) ) { 400 $where_conditions[] = "a.type != 'last_activity'"; 403 $excluded_types[] = 'last_activity'; 404 } 405 406 // Exclude 'new_member' items if xprofile component is not active 407 if ( ! bp_is_active( 'xprofile' ) ) { 408 $excluded_types[] = 'new_member'; 409 } 410 411 // Build the excluded type sql part 412 if ( ! empty( $excluded_types ) ) { 413 $not_in = "'" . implode( "', '", esc_sql( $excluded_types ) ) . "'"; 414 $where_conditions['excluded_types'] = "a.type NOT IN ({$not_in})"; 401 415 } 402 416 -
trunk/src/bp-members/bp-members-functions.php
r8654 r8818 1851 1851 */ 1852 1852 function bp_core_new_user_activity( $user ) { 1853 if ( empty( $user ) || ! bp_is_active( 'activity' ) ) {1853 if ( empty( $user ) || ! bp_is_active( 'activity' ) || ! bp_is_active( 'xprofile' ) ) { 1854 1854 return false; 1855 1855 }
Note: See TracChangeset
for help on using the changeset viewer.