diff --git a/mu-plugins/blocks/ratings-stars/render.php b/mu-plugins/blocks/ratings-stars/render.php
index fbc98a4c..c72bff10 100644
--- a/mu-plugins/blocks/ratings-stars/render.php
+++ b/mu-plugins/blocks/ratings-stars/render.php
@@ -29,12 +29,11 @@
';
- } else if ( $i + 0.5 === $display_rating ) {
+ } else if ( $i + 0.5 <= $rounded_rating ) {
echo '
';
} else {
echo '
';
@@ -45,10 +44,15 @@
' . $display_rating . '' // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
+ '' . esc_html( $display_rating_str ) . ''
);
?>