From c3ca88bea75560c59e0cfff555810c79e5e95296 Mon Sep 17 00:00:00 2001 From: Matthias Pfefferle Date: Mon, 14 Sep 2020 12:14:26 +0200 Subject: [PATCH] fix mf2 semantics see: https://chat.indieweb.org/wordpress/2020-09-14/1600074249774900 --- sempress/inc/semantics.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/sempress/inc/semantics.php b/sempress/inc/semantics.php index 6b2cd00..17e9afc 100644 --- a/sempress/inc/semantics.php +++ b/sempress/inc/semantics.php @@ -54,7 +54,11 @@ function sempress_post_classes( $classes = array() ) { $classes[] = 'no-title'; } - return $classes; + if ( ! is_singular() ) { + return sempress_get_post_classes( $classes ); + } else { + return $classes; + } } add_filter( 'post_class', 'sempress_post_classes', 99 ); @@ -286,7 +290,7 @@ function sempress_term_links_tag( $links ) { function sempress_main_class( $class = '' ) { // Separates class names with a single space, collates class names for body element - echo 'class="' . join( ' ', sempress_get_main_class( $class ) ) . '"'; + echo ' class="' . join( ' ', sempress_get_main_class( $class ) ) . '"'; } function sempress_get_main_class( $class = '' ) {