From 266aa37c48222993bf7bdad6834e31bd08736f5e Mon Sep 17 00:00:00 2001
From: Jake Vanderwerf <get@jakevanderwerf.ca>
Date: Sat, 23 May 2026 21:22:07 +0000
Subject: [PATCH] =Post type archive meta title fix

---
 inc/blocks/CustomBlocks.php |   34 ++++++++++++++++++++++------------
 1 files changed, 22 insertions(+), 12 deletions(-)

diff --git a/inc/blocks/CustomBlocks.php b/inc/blocks/CustomBlocks.php
index 0a9cc31..fc8fe8f 100644
--- a/inc/blocks/CustomBlocks.php
+++ b/inc/blocks/CustomBlocks.php
@@ -102,7 +102,7 @@
 		} else if (method_exists($this, $method)) {
 			$content = $this->$method($block, $content, $parent);
 			return $isPrerender ? $this->maybeOutputCustomStyles().$content : $content;
-		} elseif (!empty($blockName) && JVB_TESTING) {
+		} elseif (JVB_TESTING && !empty($blockName)) {
 			if (!in_array($block['blockName'], $this->getIgnore($isPrerender))) {
 				jvbDump('No method found for '.print_r($block['blockName'], true));
 			}
@@ -231,7 +231,7 @@
 
     public function prerender_core_columns(array $block, ?string $content, ?WP_Block $parent):?string
     {
-		jvbDump($block, 'columns');
+//		jvbDump($block, 'columns');
 		$attrs = $block['attrs']??[];
 		$tagName = array_key_exists('tagName', $attrs) ? $attrs['tagName'] : 'section';
 
@@ -654,7 +654,7 @@
 
     public function prerender_core_paragraph(array $block, ?string $content, ?WP_Block $parent):?string
     {
-		jvbDump($block, 'paragraph');
+//		jvbDump($block, 'paragraph');
 //		jvbDump($parent, 'Parent');
 		$inside = $this->inside($block);
         return empty($inside) ? '' : sprintf(
@@ -1359,7 +1359,10 @@
 		$inner = '';
 
 		if (!static::$currentLoop) {
-			jvbDump('No loop stored');
+
+			if (JVB_TESTING) {
+				jvbDump('No loop stored');
+			}
 			return $content;
 		}
 		if (static::$currentLoop->have_posts()) {
@@ -1799,7 +1802,7 @@
 
 	public function prerender_core_query_title(array $block, ?string $content, ?WP_Block $parent):?string
 	{
-		jvbDump($block, 'query title');
+//		jvbDump($block, 'query title');
 		$attr = $block['attrs'];
 		$name = '';
 		$showPrefix = $attr['showPrefix']??false;
@@ -1952,7 +1955,7 @@
     //core_archives
 	public function render_core_archives(array $block, string $content):string
 	{
-		jvbDump($block, 'archives');
+//		jvbDump($block, 'archives');
 		$attrs = $block['attrs']??[];
 		$isDropdown = $this->checkAttrs('displayAsDropdown', $attrs);
 
@@ -2214,7 +2217,6 @@
 		}
 		$inside = [];
 		foreach($pages->posts as $page) {
-			jvbDump($page);
 			$inside[] = sprintf(
 				'<li><a href="%s">%s</a>',
 				get_the_permalink($page->ID),
@@ -3209,7 +3211,10 @@
 							$styles['color'] = $this->getColor($v['text']);
 						}
 						if (isset($v['gradient'])) {
-							jvbDump($v, 'Gradient');
+
+							if (JVB_TESTING) {
+								jvbDump($v, 'Gradient');
+							}
 						}
 						break;
 
@@ -3279,7 +3284,9 @@
 							if ($sk === 'minHeight') {
 								$styles['min-height'] = $sv;
 							} else {
-								jvbDump('No config set for dimension '.$sk.': '.print_r($sv, true));
+								if (JVB_TESTING) {
+									jvbDump('No config set for dimension '.$sk.': '.print_r($sv, true));
+								}
 							}
 						}
 
@@ -3340,7 +3347,7 @@
 					unset($border['style']);
 					unset($border['color']);
 					if (!empty($border)) {
-						jvbDump($border,'[getBorderStyle] Leftover styles:');
+						jvbDump($border, '[getBorderStyle] Leftover styles:');
 					}
 				}
 
@@ -3443,8 +3450,11 @@
 						}, $selectors);
 						$fullSelector = implode(',', $fullSelector);
 
-						jvbDump($state, 'state');
-						jvbDump($rules, 'rules');
+
+						if (JVB_TESTING) {
+							jvbDump($state, 'state');
+							jvbDump($rules, 'rules');
+						}
 
 						if (isset($rules['color']['text']) || isset($rules['text'])) {
 							$css['color'] = $this->getColor($rules['color']['text'] ?? $rules['text']);

--
Gitblit v1.10.0