diff --git a/src/wp-includes/post-template.php b/src/wp-includes/post-template.php index a441d74231..3da42457c8 100644 --- a/src/wp-includes/post-template.php +++ b/src/wp-includes/post-template.php @@ -582,9 +582,6 @@ function get_body_class( $class = '' ) { $classes[] = 'attachment'; if ( is_404() ) $classes[] = 'error404'; - if ( is_singular() ) { - $classes[] = 'singular'; - } if ( is_single() ) { $post_id = $wp_query->get_queried_object_id(); diff --git a/tests/phpunit/tests/post/getBodyClass.php b/tests/phpunit/tests/post/getBodyClass.php index 3e3b861a64..7401ce6bf6 100644 --- a/tests/phpunit/tests/post/getBodyClass.php +++ b/tests/phpunit/tests/post/getBodyClass.php @@ -80,6 +80,7 @@ class Tests_Post_GetBodyClass extends WP_UnitTestCase { /** * @ticket 35164 + * @ticket 36510 */ public function test_singular_body_classes() { $post_id = self::factory()->post->create(); @@ -89,8 +90,6 @@ class Tests_Post_GetBodyClass extends WP_UnitTestCase { $this->assertContains( "single-post", $class ); $this->assertContains( "postid-{$post_id}", $class ); $this->assertContains( "single-format-standard", $class ); - $this->assertContains( "singular", $class ); - } }