get_price() incompatability with B2B Market by MarketPress
-
Aloha!
I noticed this issue about a week ago and was hoping for a fix, but I’m not too sure how common the following problem is so I thought I’d open a thread.
A client of ours is running a WooCommerce store in Germany with both B2C and B2B clients. We used the plugin “B2B Market” by MarketPress to show different prices to different user roles. Since WPC Product Bundles 5.9.0 was released, however, I get the following error both in the admin area and on the product archive whenever there is a product bundle displayed:
Fatal error: Uncaught Error: Maximum function nesting level of '256' reached, aborting!
This happens even without our custom theme active and pretty much everything disabled except for WooCommerce, WPC Product Bundles and B2B Market.
By digging through the code I found the culprit in the get_price() function in
class-product.php
line 120. As soon as I remove the$this->get_regular_price()
, the problem is immediately resolved.Could this be a naming issue maybe? I saw that the B2B Market also has a public function in
BM_Price::get_price
. Could those two be conflicting?It seems like when both plugins are activated
get_regular_price()
stops working on$this
.Any chance you guys can take a look? I reverted to 5.8.3 in the meantime, but a fix would be class.
Thanks!
- The topic ‘get_price() incompatability with B2B Market by MarketPress’ is closed to new replies.