WPloyalty is giving errors in debug.log with FunnelKit
-
It’s giving mostly a lot of issues when WPloyalties coupons for free products are added to FunnelKit’s minicart or checkout. The coupons don’t apply properly, many errors, very long loading time etc
[08-Jan-2025 00:56:17 UTC] PHP Warning: foreach() argument must be of type array|object, bool given in /home/sss22222/domains/xxxxxxx.cz/public_html/wp-content/plugins/wp-marketing-automations/includes/class-bwfan-common.php on line 3278Suggestions from ChatGPT
Log the values of
$items,$coupon_data, and$feesin the problematic function (get_abandoned_totals) to see how WPLoyalty is modifying the data. Add these logging lines just before theforeachloops:php
error_log('Items: ' . print_r($items, true)); error_log('Coupon Data: ' . print_r($coupon_data, true)); error_log('Fees: ' . print_r($fees, true));This will output the data being passed to
maybe_unserialize()in the debug log. By analyzing this, you can pinpoint what part of the data is invalid or incompatible.
The topic ‘WPloyalty is giving errors in debug.log with FunnelKit’ is closed to new replies.