Campo de relación ACF en discourse_publish_format_html

Para cualquiera que quiera expandir un campo de relación de ACF, esto es lo que finalmente funcionó cuando el CPT que estoy enviando a Discourse se llama memes, el cual incluye un campo de relación (como objeto) llamado meme_person que enlaza a otro CPT llamado people.

function rs_custom_publish_format_html( $output, $post_id ) {

	$post = get_post( $post_id );
	$type = get_post_type($post_id);
	
	// si hay imagen destacada, úsala
	if ( has_post_thumbnail( $post_id ) ) {
		$image = "{thumbnail}<br><br>";
	} else {
		$image = "";
	}

    // si la entrada es un meme, obtén la información del campo personalizado
    if ( 'memes' === $post->post_type) {
    	
		$comment = get_post_meta($post->ID, 'comment', true);
		$peopleout = ' ';

		$persons = get_post_meta($post->ID, 'meme_person', true);
		if( $persons ):
			foreach( $persons as $person ):
		        $title = get_the_title($person);
				$peopleout .= $title . ' ' ;
			endforeach;
		endif; ?>

        <?php ob_start(); ?>
  
        <small>Publicado originalmente en: {blogurl}</small><br><br>
        <?php echo $image ?>
        <?php echo $comment ?><br>
        <?php echo $peopleout ?>

        {excerpt}
	  
        <?php 
        $output = ob_get_clean();
        
        return $output;
    }
  
      
    // si no, devuelve
    ob_start();
    the_permalink( $post_id );
	$output = ob_get_clean();
	return $output;
    
}
add_filter( 'discourse_publish_format_html', 'rs_custom_publish_format_html', 10, 2  );