NO BUG: Error Updating to Bricks 1.9.6 - Undefined Array Key "Taxonomy" on Archive Template

Updated to 1.9.6 and i get this error on a custom archive template.

Warning: Undefined array key “taxonomy” in ---------/wp-content/themes/bricks/includes/query.php on line 1756

Fatal error: Uncaught TypeError: Cannot access offset of type string on string in /home/cedryjwl/public_html/wp-content/themes/bricks/includes/query.php:1756 Stack trace: #0 /home/cedryjwl/public_html/wp-content/themes/bricks/includes/query.php(1717): Bricks\Query::merge_tax_or_meta_query_vars(Array, Array, ‘tax’) #1 /home/cedryjwl/public_html/wp-content/themes/bricks/includes/query.php(833): Bricks\Query::merge_query_vars(Array, Array) #2 /home/cedryjwl/public_html/wp-content/themes/bricks/includes/query.php(678): Bricks\Query->run_wp_query() #3 /home/cedryjwl/public_html/wp-content/themes/bricks/includes/query.php(114): Bricks\Query->run() #4 /home/cedryjwl/public_html/wp-content/themes/bricks/includes/assets.php(2692): Bricks\Query->__construct(Array) #5 /home/cedryjwl/public_html/wp-content/themes/bricks/includes/assets.php(2727): Bricks\Assets::generate_css_from_element(Array, ‘content’) #6 /home/cedryjwl/public_html/wp-content/themes/bricks/includes/assets.php(2727): Bricks\Assets::generate_css_from_element(Array, ‘content’) #7 /home/cedryjwl/public_html/wp-content/themes/bricks/includes/assets.php(2727): Bricks\Assets::generate_css_from_element(Array, ‘content’) #8 /home/cedryjwl/public_html/wp-content/themes/bricks/includes/assets.php(2655): Bricks\Assets::generate_css_from_element(Array, ‘content’) #9 /home/cedryjwl/public_html/wp-content/themes/bricks/includes/assets.php(363): Bricks\Assets::generate_css_from_elements(Array, ‘content’) #10 /home/cedryjwl/public_html/wp-content/themes/bricks/includes/assets.php(258): Bricks\Assets::generate_inline_css() #11 /home/cedryjwl/public_html/wp-includes/class-wp-hook.php(324): Bricks\Assets::enqueue_setting_specific_scripts(‘’) #12 /home/cedryjwl/public_html/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, Array) #13 /home/cedryjwl/public_html/wp-includes/plugin.php(517): WP_Hook->do_action(Array) #14 /home/cedryjwl/public_html/wp-includes/script-loader.php(2262): do_action(‘wp_enqueue_scri…’) #15 /home/cedryjwl/public_html/wp-includes/class-wp-hook.php(324): wp_enqueue_scripts(‘’) #16 /home/cedryjwl/public_html/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, Array) #17 /home/cedryjwl/public_html/wp-includes/plugin.php(517): WP_Hook->do_action(Array) #18 /home/cedryjwl/public_html/wp-includes/general-template.php(3052): do_action(‘wp_head’) #19 /home/cedryjwl/public_html/wp-content/themes/bricks/header.php(7): wp_head() #20 /home/cedryjwl/public_html/wp-includes/template.php(790): require_once(‘/home/cedryjwl/…’) #21 /home/cedryjwl/public_html/wp-includes/template.php(725): load_template(‘/home/cedryjwl/…’, true, Array) #22 /home/cedryjwl/public_html/wp-includes/general-template.php(48): locate_template(Array, true, true, Array) #23 /home/cedryjwl/public_html/wp-content/themes/bricks/template-parts/builder.php(2): get_header() #24 /home/cedryjwl/public_html/wp-includes/template-loader.php(106): include(‘/home/cedryjwl/…’) #25 /home/cedryjwl/public_html/wp-blog-header.php(19): require_once(‘/home/cedryjwl/…’) #26 /home/cedryjwl/public_html/index.php(17): require(‘/home/cedryjwl/…’) #27 {main} thrown in /home/cedryjwl/public_html/wp-content/themes/bricks/includes/query.php on line 1756

Reverting back to 1.9.5 fixes the issue.

Well,

I went through the template and enabled the Disable Query Merge option on all my queries and it seems to have fixed the issue.

Hi @daviddemastus ,

Thanks for reporting the issue.
Shouldn’t use “Disable Query Merge” option to skip the error message.
“Disable Query Merge” should be used when your query do not want to merge with the current archive page queries.

Please can you update to the latest 1.9.6.1 and check if the issue persists without enable the Disable query megre?

If so, kindly create a staging site and send admin access to help@bricksbuilder.io. Please include this forum thread as reference as well.

Regards,
Jenn

Well, I am populating several custom post type queries on this archive page. Its a taxonomy that is shared between all of my post types, so I could see why I would maybe want to disable it.

Example, the term name could be Issue 1, and on this term archive I have news posts, podcasts, resources, books, videos that all share that term with their own “feeds” on that page.

1 Like

Alright, thanks for the explanation :slight_smile:
I will mark this thread as “NO BUG” then.