Seeming incompatibility with Page scroll to id plugin

Description:

Not sure exactly what is causing this but Cwicly, combined with the Page scroll to id plugin has the following fatal error when viewing the site:

Fatal error: Uncaught ArgumentCountError: Too few arguments to function malihuPageScroll2id::wp_menu_links_custom_atts(), 2 passed in /home/customer/www/xyz.com/public_html/wp-includes/class-wp-hook.php on line 310 and exactly 3 expected in /home/customer/www/[xxx](http://xyz.com)/public_html/wp-content/plugins/page-scroll-to-id/malihu-pagescroll2id.php:624 Stack trace: #0 /home/customer/www/[xxx](http://xyz.com)/public_html/wp-includes/class-wp-hook.php(310): malihuPageScroll2id->wp_menu_links_custom_atts(Array, Array) #1 /home/customer/www/xyz.com/public_html/wp-includes/plugin.php(205): WP_Hook->apply_filters(Array, Array) #2 /home/customer/www/xyz.com/public_html/wp-content/plugins/cwicly/core/includes/blocks/nav-menu/maker.php(54): apply_filters('nav_menu_link_a...', Array, Array) #3 /home/customer/www/xyz.com/public_html/wp-content/plugins/cwicly/core/includes/blocks/nav-menu/maker.php(248): Cwicly\NavMenu::nav_attrs(Array) #4 /home/customer/www/xyz.com/public_html/wp in /home/customer/www/xyz.com/public_html/wp-content/plugins/page-scroll-to-id/malihu-pagescroll2id.php on line 624

Step-by-step reproduction instructions:

  1. Install Cwicly
  2. Install Page scroll to id
  3. View website

We haven’t had time to test this on a clean install yet, but deactivating either the Cwicly plugin or the Page scroll to id plugin causes the error to vanish and the site can be displayed.

Environment info

  • WordPress version: 6.3
  • Cwicly Plugin version: 1.2.9.9.2

I tested this plugin some time ago without any issues.
Just added it on an existing installation and no issues either.
I’m using the default plugin settings.
Tested with a Button block, a Menu block (item), Nav block (item), and without any targeting.

We also have had it on other sites without issue - there must be a factor causing it and as of yet, it is not obvious what that is.

I am hoping @Louis will be able to shed some light based on the error message.

Hello @StrangeTech,

Thanks for the report and the detailed error which is fundamental in this case.
I can confirm an issue when using the Nav block and a Nav Menu block within.

A fix will be issue in the next update.
Apologies for the inconvenience.

Cheers,

Hello @StrangeTech,

Thanks for the report once again.
This should be addressed in 1.2.9.9.3.

If you still encounter trouble, I’d be grateful if you could let me know by replying to this thread.

Cheers,

Brilliant, thank you @Louis, I will test this tomorrow.

1 Like

Confirmed, after upgrading, no error is displayed and the site functions correctly, thank you for the quick fix @Louis.