• ResolvedModerator threadi

    (@threadi)


    Hello,

    thanks for this small and helpful plugin πŸ™‚ I have also successfully tested and installed it. However, I encountered the following error that occurs when generating the email when you submit the order in the frontend:

    [22-Apr-2025 07:41:56 UTC] PHP Fatal error:  Uncaught Error: Call to a member function put_contents() on null in /home/mhnlfilweowt/staging/wp-content/plugins/sepa-qr-code-for-woocommerce/muxp-sepaqr.php:278
    Stack trace:
    #0 /home/mhnlfilweowt/staging/wp-content/plugins/sepa-qr-code-for-woocommerce/muxp-sepaqr.php(196): muxp_set_persistent()
    #1 /home/mhnlfilweowt/staging/wp-content/plugins/sepa-qr-code-for-woocommerce/muxp-sepaqr.php(113): muxp_get_qrcode()
    #2 /home/mhnlfilweowt/staging/wp-includes/class-wp-hook.php(324): muxp_email_after_order_table()
    #3 /home/mhnlfilweowt/staging/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()
    #4 /home/mhnlfilweowt/staging/wp-includes/plugin.php(517): WP_Hook->do_action()
    #5 /home/mhnlfilweowt/staging/wp-content/plugins/woocommerce/templates/emails/email-order-details.php(90): do_action()
    #6 /home/mhnlfilweowt/staging/wp-content/plugins/woocommerce/includes/wc-core-functions.php(345): include('/home/mhnlfilwe...')
    #7 /home/mhnlfilweowt/staging/wp-content/plugins/woocommerce/includes/class-wc-emails.php(442): wc_get_template()
    #8 /home/mhnlfilweowt/staging/wp-includes/class-wp-hook.php(324): WC_Emails->order_details()
    #9 /home/mhnlfilweowt/staging/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()

    The solution to this is in the function muxp_set_persistent after

    global $wp_filesystem;

    which must be added here:

    require_once ABSPATH . '/wp-admin/includes/file.php';
    \WP_Filesystem();

    This also corresponds to the instructions here in the manual: https://developer.ww.wp.xz.cn/reference/functions/wp_filesystem/

    Would be great if you could take this into account in the next update πŸ™‚

Viewing 1 replies (of 1 total)
  • Plugin Author petermorlion

    (@petermorlion)

    Hi there!

    Thanks for using the plugin. I released version 2.0.2 with this fix. It should become visible in the plugin directory soon.

    Let me know if there’s anything else.

    Peter

Viewing 1 replies (of 1 total)

The topic ‘Error during order submission’ is closed to new replies.