Fatal error on Woocommerce update
-
I upgraded Woocommerce today to version 2.6.0 and all product pages worked fine but every other page on the website – cart, contact, about, etc – all whitescreened.
Debug showed the following error:
Fatal error: Call to a member function is_type() on boolean in /absolute/path/to/wp-content/plugins/offers-for-woocommerce/public/class-offers-for-woocommerce.php on line 809
That line is:
if ($product->is_type('variable') && is_single()) {
I edited as follows which seems to have corrected the whitescreen and fatal error:
if ($product->product_type == 'variable' && is_single()) {
Now I get a notice:
Notice: Trying to get property of non-object in /absolute/path/to/wp-content/plugins/offers-for-woocommerce/public/class-offers-for-woocommerce.php on line 809But the site works again now.
https://www.ads-software.com/plugins/offers-for-woocommerce/
- The topic ‘Fatal error on Woocommerce update’ is closed to new replies.