Prevent a notice for post types that don't support post formats. props ethitter. fixes #23534.

git-svn-id: https://develop.svn.wordpress.org/trunk@23456 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Helen Hou-Sandi 2013-02-19 20:54:03 +00:00
parent 0e5ac6c8c6
commit 6fb8f6a707
1 changed files with 2 additions and 1 deletions

View File

@ -127,10 +127,11 @@ foreach ( get_object_taxonomies( $post ) as $tax_name ) {
}
// post format
$format_class = '';
if ( post_type_supports( $post_type, 'post-formats' ) ) {
wp_enqueue_script( 'post-formats' );
$post_format = get_post_format();
$format_class = '';
if ( ! $post_format )
$post_format = 'standard';