Params incorrect on `get_the_content()`
The params are wrong here:
echo apply_filters('the_content', get_the_content($post));
Should be:
echo apply_filters('the_content', get_the_content( null, false, $post->ID ));
Per the documentation, the 3rd parameter is the Post/Post ID, not the 1st. I could see how this is missed because you aren't calling the the_content_blocks()
outside of the loop to pass in $post
. We found it when implementing the infinite scroll on Motherly where we needed to pass in the specific post.
Edited by Ryan Tvenge