• Hi,
    I am getting these warnings in my debug.log file. Can you explain how can I solve this?

    Note: I have replaced my domain with example.com

    [04-Jun-2022 02:46:49 UTC] PHP Deprecated:  Function WC_Order::reduce_order_stock is <strong>deprecated</strong> since version 3.0! Use wc_reduce_stock_levels instead. in /home/example.com/public_html/wp-includes/functions.php on line 5379
    
Viewing 4 replies - 1 through 4 (of 4 total)
  • First of all, you should install all pending plugin updates. One of them will be responsible for the message. If the updates don’t solve the problem, take a look at what plugins you have besides the WooCommerce you use that could use WooCommerce’s order functions. If there is a plugin that has not been updated for a very long time, then that is the reason for the message.

    Thread Starter Vishal Lohar

    (@vlohar08)

    Here is the list of all my plugins – https://drive.google.com/file/d/15jZQVRLSOcHnps4mrmySK7mkbnwvzgMh

    All plugins are regularly updated hence Update didn’t fix the issue.

    There are plugins like Order Import Export and Order Status but I don’t think they want to change Product stock.

    There is a plugin called WooCommerce Product Stock Alert and I think this plugin can be the problem.

    What do you think?

    I can’t tell you because I don’t know most of the plugins. However, the plugin “WooCommerce PDF Invoices, Packing Slips, Delivery Notes & Shipping Labels” in the Pro version is striking. The free one recently got an update to 3.0.0 – did you get that with the Pro version too?

    You might want to disable plugins and see if that fixes the problem. Once the message no longer appears, you know that one of the deactivated plugins is responsible.

    Thread Starter Vishal Lohar

    (@vlohar08)

    Yes, I got the update but my version is 4.3.0 which is the latest.
    I will disable the plugins to find the plugin that triggered this problem.

    Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘PHP Deprecated: Function WC_Order’ is closed to new replies.