Skip to content

Commit

Permalink
Merge branch 'PFWMA-294' of https://github.com/angelleye/paypal-for-w…
Browse files Browse the repository at this point in the history
  • Loading branch information
kcppdevelopers committed Feb 24, 2023
2 parents bdacdc5 + 5ada61a commit 974e772
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions includes/angelleye-multi-account-function.php
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ function angelleye_pfwma_log($message, $level = 'info') {

function angelleye_display_checkout_custom_field() {
$woo_custome_fields = array();
if(!function_exists('WC')) {
if (!function_exists('WC')) {
return $woo_custome_fields;
}
$woo_checkout_default_fields = array(
Expand Down Expand Up @@ -150,12 +150,11 @@ function angelleye_display_checkout_custom_field() {
}

return $woo_custome_fields;

}

function angelleye_get_checkout_custom_field_keys() {
$woo_custome_fields = array();
if(!function_exists('WC')) {
if (!function_exists('WC')) {
return $woo_custome_fields;
}
$woo_checkout_default_fields = array(
Expand All @@ -170,6 +169,9 @@ function angelleye_get_checkout_custom_field_keys() {
* Resolves PFWMA-294
* [email protected]
*/

$checkout_fields = WC()->checkout->get_checkout_fields();

foreach ($checkout_fields as $type => $checkout_field) {
if (isset($woo_checkout_default_fields[$type]) && is_array($woo_checkout_default_fields[$type])) {
foreach ($checkout_field as $key => $field) {
Expand Down

0 comments on commit 974e772

Please sign in to comment.