From fe10a9b05b39fc4b1d91145d6c4a94ea378b50b0 Mon Sep 17 00:00:00 2001 From: Joe Dolson Date: Sat, 11 May 2024 00:26:21 -0500 Subject: [PATCH] Change $details to boolean false if empty --- src/templates/legacy-functions.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/templates/legacy-functions.php b/src/templates/legacy-functions.php index f9da5235..8f4ddde8 100644 --- a/src/templates/legacy-functions.php +++ b/src/templates/legacy-functions.php @@ -78,6 +78,8 @@ function mc_legacy_template_draw_event( $event, $type, $process_date, $time, $te $template = apply_filters( 'mc_use_custom_template', $template, $tags, $event, $type, $process_date, $time ); if ( false === $details ) { $details = wp_kses_post( mc_get_details( $tags, $template, $type ) ); + // Set details to false if it has no content. + $details = ( '' === trim( strip_tags( $details ) ) ) ? false : $details; } }