From 8ffd02258124c917f2d44cf85fd4cd2e60362030 Mon Sep 17 00:00:00 2001 From: ryan Date: Mon, 15 Jun 2009 00:28:52 +0000 Subject: [PATCH] Add missing brackets. Props westonruter. fixes #8446 for trunk git-svn-id: http://svn.automattic.com/wordpress/trunk@11567 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/post-template.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/wp-includes/post-template.php b/wp-includes/post-template.php index 30856c584..71ba4bdd6 100644 --- a/wp-includes/post-template.php +++ b/wp-includes/post-template.php @@ -430,13 +430,14 @@ function get_body_class( $class = '' ) { if ( $wpdb->get_var( $wpdb->prepare("SELECT ID FROM $wpdb->posts WHERE post_parent = %d AND post_type = 'page' LIMIT 1", $pageID) ) ) $classes[] = 'page-parent'; - if ( $wp_query->post->post_parent ) + if ( $wp_query->post->post_parent ) { $classes[] = 'page-child'; $classes[] = 'parent-pageid-' . $wp_query->post->post_parent; - - if ( is_page_template() ) + } + if ( is_page_template() ) { $classes[] = 'page-template'; $classes[] = 'page-template-' . str_replace( '.php', '-php', get_post_meta( $pageID, '_wp_page_template', true ) ); + } } elseif ( is_search() ) { if ( !empty($wp_query->posts) ) $classes[] = 'search-results';