• Resolved grahamsg

    (@grahamsg)


    Getting the following error code on all outgoing emails whgen order completed email is sent.
    Notice: Function customer_user was called?incorrectly. Order properties should not be accessed directly. Backtrace: edit_post, wp_update_post, wp_insert_post, do_action(‘save_post’), WP_Hook->do_action, WP_Hook->apply_filters, WC_Admin_Meta_Boxes->save_meta_boxes, do_action(‘woocommerce_process_shop_order_meta’), WP_Hook->do_action, WP_Hook->apply_filters, WC_Meta_Box_Order_Data::save, WC_Order->save, WC_Order->status_transition, do_action(‘woocommerce_order_status_completed’), WP_Hook->do_action, WP_Hook->apply_filters, WC_Emails::send_transactional_email, do_action_ref_array(‘woocommerce_order_status_completed_notification’), WP_Hook->do_action, WP_Hook->apply_filters, WC_Email_Customer_Completed_Order->trigger, WC_Email->get_content, WC_Email_Customer_Completed_Order->get_content_html, wc_get_template_html, wc_get_template, include(‘/plugins/woocommerce/templates/emails/customer-completed-order.php’), do_action(‘woocommerce_email_customer_details’), WP_Hook->do_action, WP_Hook->apply_filters, gens in?/home/lipsungl/public_html/wp-includes/functions.php?on line?5865

    What is the cause and what is the fix for this?

    Thanks

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hello,

    That sounds like the site is making a reference to the functions.php file, it is possible the site is using some custom code when the order completed email is sent.

    Can you provide a screenshot of the error on your end?

    I completed an order on my testing site, but I was unable to see the same behavior.

    If the site is using custom code, can you temporarily disable it to see if the issue persists after that? If that does not help, I’d suggest running a full conflict test: https://woocommerce.com/document/woocommerce-self-service-guide/#section-4 to help you find the cause of the issue,

    Let us know if there are any questions.

    • This reply was modified 1 year, 9 months ago by Igor H.
    Thread Starter grahamsg

    (@grahamsg)

    Hi Igor

    Thanks for the suggestions and pointers. I found that the issues was caused by a code snippet. After removing the snippet, the error disappeared. Thanks for your help. You Nailed it.

    Graham

    Hi @grahamsg

    I’m glad you were able to find a solution to your issue here and thanks for sharing it with the community too! ??

    I will be marking this thread as resolved. Should you have further inquiries, kindly create a new topic here.

    Meanwhile, if you have a moment to spare, we would love it if you could share your thoughts with us by leaving a review or feedback. Your experience and feedback are important to help us improve and ensure we’re always providing the best possible support.

    Thanks!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Notice: Function customer_user was called incorrectly.’ is closed to new replies.