Changeset 9621 for trunk/src/bp-activity/bp-activity-filters.php
- Timestamp:
- 03/16/2015 06:59:09 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-activity/bp-activity-filters.php
r9475 r9621 387 387 * Truncate long activity entries when viewed in activity streams. 388 388 * 389 * This method can only be used inside the Activity loop. 390 * 389 391 * @since BuddyPress (1.5.0) 390 392 * … … 403 405 global $activities_template; 404 406 407 /** 408 * Provides a filter that lets you choose whether to skip this filter on a per-activity basis. 409 * 410 * @param bool $maybe_truncate_text If true, text should be checked to see if it needs truncating. 411 * @since BuddyPress (2.3.0) 412 */ 413 $maybe_truncate_text = apply_filters( 'bp_activity_maybe_truncate_entry', 414 ! in_array( $activities_template->activity->type, array( 'new_blog_post', ), true ) 415 ); 416 405 417 // The full text of the activity update should always show on the single activity screen 406 if ( bp_is_single_activity() )418 if ( ! $maybe_truncate_text || bp_is_single_activity() ) { 407 419 return $text; 420 } 408 421 409 422 /**
Note: See TracChangeset
for help on using the changeset viewer.