This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function my_custom_roles( $role, $user_id, $user_role ) { | |
if( $role == 'Key Master' ) | |
return 'Site Owner'; | |
return $role; | |
} | |
add_filter( 'bbp_get_user_display_role', 'my_custom_roles', 10, 3 ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function _bbp_has_replies_where( $where, $query ) { | |
// Bail if no post_parent to replace | |
if ( ! is_numeric( $query->get( 'post_parent' ) ) ) | |
return $where; | |
// Bail if not a topic and reply query | |
if ( array( bbp_get_topic_post_type(), bbp_get_reply_post_type() ) != $query->get( 'post_type' ) ) | |
return $where; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// add_filter( 'bbp_get_topic_reply_count', 'bbp_number_format', 10 ); | |
add_filter( 'bbp_topic_reply_count', 'bbp_number_format', 10 ); |
NewerOlder