There’s actually nothing to fix.
In Twenty Eleven, this is used in index.php
:
<?php get_template_part( 'content', get_post_format() ); ?>
…and this is used in single.php
:
<?php get_template_part( 'content', 'single' ); ?>
The design intent here is that all posts, regardless of post format, will display the same in single-post view, but that posts with defined post formats will have a custom display in archive indexes.
If you have a different design intent – e.g. you want to use the post-format custom display in the single-post view, simply change the call in single.php
from this:
<?php get_template_part( 'content', 'single' ); ?>
…to this:
<?php get_template_part( 'content', get_post_format() ); ?>
Likewise, if you want to call content-single.php
from within index.php
, you’d need to change the call the other way around, perhaps like so:
if ( get_post_format() ) {
get_template_part( 'content', get_post_format() );
} else {
get_template_part( 'content', 'single' );
}
Another approach:
$postformat = ( get_post_format() ? get_post_format() : 'single' );
get_template_part( 'content', $postformat );
Either should result in the same thing.