WC Blocks error with multi-currency site
-
I’m getting this error in the Hand-picked Products block:
[29-Jul-2020 03:06:49 UTC] PHP Fatal error: Uncaught Error: Call to undefined function wc_get_chosen_shipping_method_ids() in /www/wp-content/plugins/woocommerce/includes/class-wc-customer.php:190 Stack trace: #0 /www/wp-content/plugins/woocommerce/includes/class-wc-tax.php(459): WC_Customer->get_taxable_address() #1 /www/wp-content/plugins/woocommerce/includes/class-wc-tax.php(481): WC_Tax::get_tax_location('', Object(WC_Customer)) #2 /www/wp-content/plugins/woocommerce/includes/wc-product-functions.php(987): WC_Tax::get_rates('') #3 /www/wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/StoreApi/Schemas/ProductSchema.php(316): wc_get_price_including_tax(Object(WC_Product_Simple)) #4 /www/wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/StoreApi/Schemas/ProductSchema.php(244): Automattic\WooCommerce\Blocks\StoreApi\Schemas\ProductSchema->prepare_product_price_response(Object(WC_Product_Simple)) #5 /www/wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/StoreApi/Routes/Products.php(62): Automattic\WooCommerce\Bloc in /www/wp-content/plugins/woocommerce/includes/class-wc-customer.php on line 190
Screenshot of error: https://imgur.com/a/WQJZL7A
After some debugging I realized that it’s due to the multiple currencies on my site. After deactivating the plugin in question (Price Based on Country and the Pro add-on), the block no longer crashes. I’ll report this to Oscar the developer too.
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘WC Blocks error with multi-currency site’ is closed to new replies.