* Prevent billing address from being updated on shipping update. * Set billing address if empty. * Fix coding standard issue. * Fixed missing tab
This commit is contained in:
parent
6bdb7f7a83
commit
b8217fa080
|
@ -40,7 +40,9 @@ class WC_Shortcode_Cart {
|
|||
}
|
||||
|
||||
if ( $address['country'] ) {
|
||||
WC()->customer->set_billing_location( $address['country'], $address['state'], $address['postcode'], $address['city'] );
|
||||
if ( ! WC()->customer->get_billing_first_name() ) {
|
||||
WC()->customer->set_billing_location( $address['country'], $address['state'], $address['postcode'], $address['city'] );
|
||||
}
|
||||
WC()->customer->set_shipping_location( $address['country'], $address['state'], $address['postcode'], $address['city'] );
|
||||
} else {
|
||||
WC()->customer->set_billing_address_to_base();
|
||||
|
|
Loading…
Reference in New Issue