Support » Plugin: Back In Stock Notifier for WooCommerce | WooCommerce Waitlist Pro » PHP Fatal error with no variation product

  • Resolved JohnnyPea

    (@johnnypea)


    Your plugin throws this error when used with YITH WooCommerce Gift Cards but I think any “no variation” product can be an issue.

    PHP Fatal error: Call to undefined method WC_Product_Gift_Card::get_available_variations() in /var/www/html/wp-content/plugins/back-in-stock-notifier-for-woocommerce/includes/frontend/class-product.php:28

    The problem is in back-in-stock-notifier-for-woocommerce/includes/frontend/class-product.php:27 where you have the wrong condition. I suppose this should be $get_variations = count($product->get_children());. Please, check it out.

    Have nice day!

    • This topic was modified 2 years, 2 months ago by JohnnyPea.
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘PHP Fatal error with no variation product’ is closed to new replies.