return $is_debug ?
// translators: Visible only in the front end, this warning takes the place of a faulty block.
__( '[block rendering halted]'
) :
'';
} $seen_ids[ $post_id ] = true;
// Check is needed for backward compatibility with third-party plugins
// that might rely on the `in_the_loop` check; calling `the_post` sets it to true.
if ( !
in_the_loop() &&
have_posts() ) { the_post();
} // When inside the main loop, we want to use queried object
// so that `the_preview` for the current post can apply.
// We force this behavior by omitting the third argument (post ID) from the `get_the_content`.
$content =
get_the_content();
// Check for nextpage to display page links for paginated posts.
if ( has_block( 'core/nextpage'
) ) { $content .=
wp_link_pages( array
( 'echo' => 0
) );
}