• Resolved Jaap de Wit

    (@hitec4ever)


    Hi,

    When opening certain orders I receive a fatal error.

    Een fout van het type E_ERROR werd veroorzaakt op regelnummer 2256 van het bestand /home/x.cloudwaysapps.com/xtkcqmyfpn/public_html/wp-content/plugins/woocommerce/includes/class-wc-order.php. Foutmelding: Uncaught Error: Call to a member function get_items() on int in /home/x.cloudwaysapps.com/xtkcqmyfpn/public_html/wp-content/plugins/woocommerce/includes/class-wc-order.php:2256
    Stack trace: 0 /home/x.cloudwaysapps.com/xtkcqmyfpn/public_html/wp-content/plugins/woocommerce/includes/admin/meta-boxes/views/html-order-item.php(62): WC_Order->get_qty_refunded_for_item() 1 /home/x.cloudwaysapps.com/xtkcqmyfpn/public_html/wp-content/plugins/woocommerce/includes/admin/meta-boxes/views/html-order-items.php(75): include(‘/home/x.cl…’) 2 /home/x.cloudwaysapps.com/xtkcqmyfpn/public_html/wp-content/plugins/woocommerce/includes/admin/meta-boxes/class-wc-meta-box-order-items.php(40): include(‘/home/x.cl…’) 3 /home/x.cloudwaysapps.com/xtkcqmyfpn/public_html/wp-admin/includes/template.php(1456): WC_Meta_Box_Order_Items::output() 4 /home/x.cloudwaysapps.com/xtkcqmyfpn/public_html/wp-admin/edit-form-advanced.php(722): do_meta_boxes() 5 /home/x.cloudwaysapps.com/xtkcqmyfpn/public_html/wp-admin/post.php(206): require(‘/home/209144.cl…’) 6 {main} thrown

    https://snipboard.io/WnPlHQ.jpg

    I’ve tried opening with only WooCommerce and default theme enabled but this didn’t solve the issue.

    How can this be fixed?

    Cheers,
    Jaap

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support shahzeen(woo-hc)

    (@shahzeenfarooq)

    Hi there!

    I understand you’re encountering a fatal error, and from your screenshot, I can see you’re receiving a critical error message when trying to access an order in the backend.

    Since you mentioned that you’re still encountering the same error even with only the default theme and WooCommerce enabled, I’d like to understand your site setup better in order to assist you further. Please provide the necessary information below so we can investigate the issue:

    • System Status Report which you can find via WooCommerce > Status
    • Fatal error logs (if any) under WooCommerce > Status > Logs.

    Please use https://pastebin.com/ or https://gist.github.com/ and share a link to that paste in reply here. Once we have more information, we’ll be able to assist you further

    Thread Starter Jaap de Wit

    (@hitec4ever)

    Hi @shahzeenfarooq

    Thanks for your reply. You can find the files here.
    System status: https://pastebin.com/3uZufPYt
    Fatal error log: https://pastebin.com/v4uPayRC

    Hope you can help me out.
    Cheers,
    Jaap

    Plugin Support shahzeen(woo-hc)

    (@shahzeenfarooq)

    Hi there,

    Thank you for sharing the system status report and error log.

    I’ve reviewed the error log, and it appears that some code on your site possibly from a custom snippet or a plugin is calling a function on an order incorrectly. This is likely causing the error when you try to access the Orders section.

    To troubleshoot this, could you please create a staging site for testing? You can use the following plugin to do that:
    🔗 WP Staging

    Once the staging site is ready, please try the following:

    1. Deactivate all plugins except WooCommerce.
    2. Switch to a default WordPress theme like Storefront.
    3. Try accessing the orders again and let me know if the issue persists.

    For more details on how to perform a conflict test, you can follow this guide:
    🔗 How to Test for Conflicts

    Thank you!

    Plugin Support Kay U a11n

    (@kingsleyinfo)

    We haven’t heard back from you in a while, so I’m going to mark this as resolved.

    If you have a few minutes, we’d love if you could leave us a review: https://ww.wp.xz.cn/support/plugin/woocommerce/reviews/

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Fatal error when opening orders’ is closed to new replies.