mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-05 08:59:14 +08:00
Minor condition refactor
This commit is contained in:
parent
7672f66bcf
commit
00e1e16fa5
1 changed files with 2 additions and 4 deletions
|
@ -637,12 +637,10 @@ document.querySelector("#payment").before(document.querySelector(".ppcp-messages
|
|||
$messaging_enabled_for_current_location = $this->settings_status->is_pay_later_messaging_enabled_for_location( $location );
|
||||
|
||||
$has_paylater_block =
|
||||
PayLaterBlockModule::is_block_enabled( $this->settings_status ) &&
|
||||
has_block('woocommerce-paypal-payments/paylater-messages') ||
|
||||
has_block('woocommerce-paypal-payments/checkout-paylater-messages') ||
|
||||
(
|
||||
has_block('woocommerce-paypal-payments/cart-paylater-messages') &&
|
||||
PayLaterBlockModule::is_block_enabled( $this->settings_status )
|
||||
);
|
||||
has_block('woocommerce-paypal-payments/cart-paylater-messages');
|
||||
|
||||
switch ( $location ) {
|
||||
case 'checkout':
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue