CoCart v2.6.0 Release Candidate 1

CoCart is getting better and by that I mean with backwards compatibility, listening to users feedback and optimized better for future releases of WooCommerce.

WooCommerce 4.5 will be released on the 8th September which CoCart will release v2.6.0 just hours before so you can update with ease.

WooCommerce decided to bring back their REST API to the core of WooCommerce which changed a few things with the loading of the REST API but also made it better for CoCart Lite and the coming update of CoCart Pro. 💜

With that change I was able to evaluate the code base for CoCart Lite and make some adjustments to keep CoCart maintained as is but opened more opportunities, some based on what my users have been asking for.

One thing I did apply is to check the site environment before CoCart is activated. This way users are actually notified if the environment does not meet the plugin minimum requirements before activating.

Previous notifications were added for WordPress and WooCommerce only telling users they had to upgrade either but not the environment.

While checks are in place to prevent the plugin from causing any fatal error if either requirement don’t meet once the plugin is activated, checking the site environment was missing.

So now if any of the plugin requirements do not meet, the plugin will automatically deactivate. It also means I won’t have to worry of getting support tickets from users who don’t have those minimum requirements.

I have also given site owners a little more control over CoCart which can be controlled via their wp-config.php file. This ensures only the site owner can perform certain actions.

Again this is a minor release and no changes to the CoCart API have changed.

Changelog

  • NEW: Added backwards compatibility for when set_customer_session_cookie() function is called.
  • NEW: Site environment is now checked before plugin activates.
  • NEW: Plugin will not activate if CoCart Pro v1.1.0 or above is installed.
  • Enhanced: Plugin to be better optimized for future releases of WooCommerce and to allow it to be packaged with CoCart Pro so user’s will not require CoCart Lite if Pro is installed.
  • Improved: uninstall.php file and now will only clear plugin data and remove the database table if COCART_REMOVE_ALL_DATA constant is set to true in user’s wp-config.php. This is to prevent data loss when deleting the plugin from the backend and to ensure only the site owner can perform this action.
  • Improved: Handling of admin menu by moving to it’s own class.
  • Tweaked: Admin notices to not redirect only to the plugins page once notice is dismissed. Will redirect to the current admin page.
  • Dev: Introduced the ability to white label the plugin. Meaning hide CoCart from the backend. (Admin menu, plugin links, plugin notices including WC admin inbox notices and WC system status information). All you have to do is set a constant COCART_WHITE_LABEL to true in user’s wp-config.php file.
  • Dev: New filter cocart_authenticate to override the determined user ID when authenticating. NOTE This will only be active if not already authenticated.
  • Tested: Compatible with WooCommerce v4.5.0

Testing

If you’d like to dive in and help test this new release, a handy CoCart Beta Tester allows you to download the latest beta version or release candidates from the CoCart GitHub repository before final release.

If you discover any bugs during the testing process, please let me know by logging a report in GitHub.

Thanks to all of my testers and contributors!

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.