Ticket #7809: 7809.02.patch
File 7809.02.patch, 1.5 KB (added by , 7 years ago) |
---|
-
src/bp-messages/bp-messages-star.php
364 364 return $retval; 365 365 } 366 366 add_filter( 'bp_get_the_thread_message_css_class', 'bp_messages_star_message_css_class' ); 367 368 /** 369 * Filter message threads by those starred by the logged-in user. 370 * 371 * @since 2.3.0 372 * 373 * @param array $r Current message thread arguments. 374 * @return array $r Array of starred message threads. 375 */ 376 function bp_messages_filter_starred_message_threads( $r = array() ) { 377 $r['box'] = 'starred'; 378 $r['meta_query'] = array( array( 379 'key' => 'starred_by_user', 380 'value' => $r['user_id'] 381 ) ); 382 383 return $r; 384 } -
src/bp-messages/screens/starred.php
40 40 // Remove our filter. 41 41 remove_filter( 'bp_after_has_message_threads_parse_args', 'bp_messages_filter_starred_message_threads' ); 42 42 } 43 44 /**45 * Filter message threads by those starred by the logged-in user.46 *47 * @since 2.3.048 *49 * @param array $r Current message thread arguments.50 * @return array $r Array of starred message threads.51 */52 function bp_messages_filter_starred_message_threads( $r = array() ) {53 $r['box'] = 'starred';54 $r['meta_query'] = array( array(55 'key' => 'starred_by_user',56 'value' => $r['user_id']57 ) );58 59 return $r;60 }61 No newline at end of file