I am getting Critical Error when i am trying to register new customer
-
You can find the error below-
[Fri Nov 26 14:15:41.894235 2021] [php7:error] [pid 25024] [client 103.46.203.81:0] PHP Fatal error: Uncaught Error: Call to a member function get_billing_first_name() on null in /nas/content/live/tellihealth/wp-content/themes/twentytwentyone-child/functions.php:1028nStack trace:n#0 /nas/content/live/tellihealth/wp-includes/class-wp-hook.php(305): new_customer_registered_send_email_admin(204731430)n#1 /nas/content/live/tellihealth/wp-includes/class-wp-hook.php(327): WP_Hook->apply_filters(NULL, Array)n#2 /nas/content/live/tellihealth/wp-includes/plugin.php(470): WP_Hook->do_action(Array)n#3 /nas/content/live/tellihealth/wp-content/plugins/woocommerce/includes/wc-user-functions.php(105): do_action(‘woocommerce_cre…’, 204731430, Array, false)n#4 /nas/content/live/tellihealth/wp-content/plugins/woocommerce/includes/class-wc-form-handler.php(1092): wc_create_new_customer(‘amandashing15@g…’, ‘amandashing15’, ‘Amangupta@1234’)n#5 /nas/content/live/tellihealth/wp-includes/class-wp-hook.php(303): WC_Form_Handler::process_registration(”)n#6 /nas/content/live/tellihealth/wp-includes/class-wp-hook.php(327): WP_Hoo in /nas/content/live/tellihealth/wp-content/themes/twentytwentyone-child/functions.php on line 1028, referer: https://tellihealth.wpengine.com/my-account/
Reference code that define the error on line-
function new_customer_registered_send_email_admin($customer_id)
{$user = get_user_by( ‘id’, $customer_id );
$fullname = $order->get_billing_first_name().’ ‘.$order->get_billing_last_name();sendgrid_send_mail(‘{‘personalizations’:[{‘to’:[{’email’:”.$user->user_email.”,’name’:”.$fullname.”}]}],’from’:{’email’:'(email visible only to moderators and staff)’,’name’:’tellihealth’},’reply_to’:{’email’:”.$user->user_email.”,’name’:”.$fullname.”},’template_id’:’d-d10a9fe177504e85a6c9bd297128477a’}’);
}
add_filter( ‘woocommerce_login_redirect’, ‘my_login_redirect’, 9999, 2 );
WP.com: Unknown
Jetpack: Unknown
Correct account: UnknownThe blog I need help with is: (visible only to logged in users)
-
Hello there,
It looks like this site is hosted with WP Engine.
You would need to reach out for help here: https://wpengine.com/support/#
I hope this helps.
- The topic ‘I am getting Critical Error when i am trying to register new customer’ is closed to new replies.