mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-08-31 06:52:50 +08:00
♻️ Deprecate old config-services
This commit is contained in:
parent
c310151f1f
commit
236188af34
5 changed files with 15 additions and 17 deletions
|
@ -22,12 +22,11 @@ use WooCommerce\PayPalCommerce\ApiClient\Helper\CurrencyGetter;
|
|||
|
||||
return array(
|
||||
|
||||
// If AXO can be configured.
|
||||
// @deprecated - use `axo.eligibility.check` instead.
|
||||
'axo.eligible' => static function ( ContainerInterface $container ): bool {
|
||||
$apm_applies = $container->get( 'axo.helpers.apm-applies' );
|
||||
assert( $apm_applies instanceof ApmApplies );
|
||||
$eligibility_check = $container->get( 'axo.eligibility.check' );
|
||||
|
||||
return $apm_applies->for_country_currency() && $apm_applies->for_merchant();
|
||||
return $eligibility_check();
|
||||
},
|
||||
'axo.eligibility.check' => static function ( ContainerInterface $container ): callable {
|
||||
$apm_applies = $container->get( 'axo.helpers.apm-applies' );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue