Merge pull request #13793 from woocommerce/fix-13785
Load values only when not-empty/set
This commit is contained in:
commit
ae7c4e713b
|
@ -981,8 +981,8 @@ class WC_Checkout {
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( is_callable( array( WC()->customer, "get_$input" ) ) ) {
|
if ( is_callable( array( WC()->customer, "get_$input" ) ) ) {
|
||||||
$value = WC()->customer->{"get_$input"}();
|
$value = WC()->customer->{"get_$input"}() ? WC()->customer->{"get_$input"}() : null;
|
||||||
} else {
|
} elseif ( WC()->customer->meta_exists( $input ) ) {
|
||||||
$value = WC()->customer->get_meta( $input, true );
|
$value = WC()->customer->get_meta( $input, true );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue