I have a script for "BP Nouveau template pack" which unfortunately doesn't work. What pack is used for the template?
/**
* Filter ajax post request
*/
function buddydev_restrict_post_update() {
// Always allow site admin.
if ( is_super_admin() ) {
return;
}
$object = empty( $_POST['object'] ) ? '' : sanitize_key( $_POST['object'] );
// Allowed user ids.
$allowed_user_ids = array( 10 );
if ( 'user' == $object && ! in_array( get_current_user_id(), $allowed_user_ids ) ) {
wp_send_json_error( array( 'message' => __( 'You are not allowed to post activity.' ) ) );
}
}
add_action( 'wp_ajax_post_update', 'buddydev_restrict_post_update', 9 );
Theme doesn't use any template packs. You can find theme's templates in
buddypress folder of theme