From d94a594def9855014c3080c1933d7cb2a6d1ad07 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Wed, 21 Oct 2020 00:29:35 +0200 Subject: update snippets --- snippets/oidc-woocommerce.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/snippets/oidc-woocommerce.php b/snippets/oidc-woocommerce.php index 1178037..904c78c 100644 --- a/snippets/oidc-woocommerce.php +++ b/snippets/oidc-woocommerce.php @@ -27,7 +27,7 @@ add_action( // Show login form at the shopping cart (if not logged in). add_action( 'woocommerce_before_checkout_billing_form', - function () use ( $login_form ) { + function ( $checkout ) use ( $login_form ) { $user = wp_get_current_user(); if ( 0 === $user->ID ) { // ID 0 is used to indicate user is not logged in. @@ -41,8 +41,8 @@ add_action( // (checkout) page after OIDC provided the data. add_action( 'woocommerce_before_checkout_billing_form', - function () use ( $login_form ) { - handle_redirect_cookie ( $login_form ); + function ( $checkout ) use ( $login_form ) { + $login_form->handle_redirect_cookie ( ); } ); -- cgit v1.2.3