greatwitenorth / quantities-and-units-for-woocommerce

Add unit support to items and allow decimal quantities in WooCommerce.
GNU General Public License v2.0
9 stars 18 forks source link

Proposal for Plugin Handover & PHP8 Compatibility Update #19

Open eHtmlu opened 5 days ago

eHtmlu commented 5 days ago

Hi Nick,

[!IMPORTANT] I noticed that the plugin hasn’t been maintained for a few years. Can you imagine handing over the plugin to another developer? I would be interested. 😉 Please let me know what you think about it. 🙏🙂

This pull request updates the comparison operators, as PHP8 changed their interpretation and this caused problems.

Example: PHP7: "" == 0 results in TRUE PHP8: "" == 0 results in FALSE

To solve this, I frequently used the empty() function to restore the old behavior as best as possible.

Best regards, Helmut