nfd_wpnavbar_setting, Notice: Function wp_enqueue_script was called incorrectly.
Summarize the issue (briefly)
Got this error message: Notice: Function wp_enqueue_script was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the nfd_wpnavbar_setting handle. Steps to reproduce
- Go to...
- Click on...
- Scroll down to...
- See/experience error
Expected behavior
Screenshots
the problem was here and where it was being called above these lines in this function "set_wpnav_collapse_setting"
Bluehost Plugin Version:
- Version: 3.9.3
Browser (with version) & Operating System (with version)
- Browser: Chrome
- Operating System: MacOS
- Device: m1. M1 Pro Laptop
Additional context
This file is in /vendor/newfold-labs/wp-module-ecommerce/includes/ECommerce.php
Thanks for the report @cardfaux - we will look into it and get it fixed in an upcoming release.
@cardfaux the fix for this is expected to be released May 1st in a new version of the plugin. Thanks again for the report.
@chrisdavidmiles Code fixes are completed. You can review the same in PR cc: @cardfaux