New Landing How can we help? Themeforest Theme Support Neighborhood My Orders screen brings up error message after woocommerce update

Viewing 8 posts - 1 through 8 (of 8 total)
  • #113050
    deanjohn
    Member
    Post count: 93

    Hi,

    I updated woocommerce but receiving the attached error on the My Orders screen inside the My Account section.

    Every time a user views the order this Warning message appears:

    Warning: Missing argument 1 for WC_Order::__construct(), called in /home/public_html/domain.com/wp-content/themes/neighborhood1.9/woocommerce/myaccount/my-orders.php on line 46 and defined in /home/public_html/domain.com/wp-content/plugins/woocommerce/includes/class-wc-order.php on line 19

    Please can you help?
    regards,

    Dean

    #113054
    deanjohn
    Member
    Post count: 93

    resolved, just this sec did your new update

    #113231
    Rui Guerreiro – SUPPORT
    Keymaster
    Post count: 25779

    Glad it’s sorted.
    -Rui

    #115074
    Mokey_Arts
    Member
    Post count: 2

    Hi,
    I have the same problem:
    Warning: Missing argument 1 for WC_Order::__construct()

    Thanks
    Barbara

    #115268
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,

    @Mokey_Arts
    – Please upgrade latest version of theme and woocommerce to resolve the issue .
    Thanks
    Mohammad

    #117850
    crease
    Member
    Post count: 101

    if you are still having problems you need to change the code in the my-orders.php file.

    Replacing

    $order = new WC_Order();
    $order->populate( $customer_order );

    with

    $order = new WC_Order( $customer_order );

    #117852
    Mokey_Arts
    Member
    Post count: 2

    Hi,
    thank you! now it works 🙂

    Barbara

    #117855
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    I am glad that your issue resolved.
    Thanks
    Mohamad

Viewing 8 posts - 1 through 8 (of 8 total)

You must be logged in and have valid license to reply to this topic.

License required for one of the following items
Login and Registration Log in · Register