Remove unnecessary dependency

This commit is contained in:
Narek Zakarian 2022-08-19 16:40:59 +04:00
parent 9096a9f111
commit b68673e941
2 changed files with 2 additions and 12 deletions

View file

@ -2303,8 +2303,7 @@ return array(
'wcgateway.pay-upon-invoice-helper' => static function( ContainerInterface $container ): PayUponInvoiceHelper { 'wcgateway.pay-upon-invoice-helper' => static function( ContainerInterface $container ): PayUponInvoiceHelper {
return new PayUponInvoiceHelper( return new PayUponInvoiceHelper(
$container->get( 'wcgateway.checkout-helper' ), $container->get( 'wcgateway.checkout-helper' ),
$container->get( 'api.shop.country' ), $container->get( 'wcgateway.settings' )
$container->get( 'wcgateway.pay-upon-invoice-product-status' )
); );
}, },
'wcgateway.pay-upon-invoice-product-status' => static function( ContainerInterface $container ): PayUponInvoiceProductStatus { 'wcgateway.pay-upon-invoice-product-status' => static function( ContainerInterface $container ): PayUponInvoiceProductStatus {

View file

@ -25,13 +25,6 @@ class PayUponInvoiceHelper {
*/ */
protected $checkout_helper; protected $checkout_helper;
/**
* The selected shop country.
*
* @var string
*/
protected $shop_country;
/** /**
* The settings. * The settings.
* *
@ -43,13 +36,11 @@ class PayUponInvoiceHelper {
* PayUponInvoiceHelper constructor. * PayUponInvoiceHelper constructor.
* *
* @param CheckoutHelper $checkout_helper The checkout helper. * @param CheckoutHelper $checkout_helper The checkout helper.
* @param string $shop_country The selected shop country.
* @param Settings $settings The Settings. * @param Settings $settings The Settings.
*/ */
public function __construct( CheckoutHelper $checkout_helper, string $shop_country, Settings $settings ) { public function __construct( CheckoutHelper $checkout_helper, Settings $settings ) {
$this->checkout_helper = $checkout_helper; $this->checkout_helper = $checkout_helper;
$this->shop_country = $shop_country;
$this->settings = $settings; $this->settings = $settings;
} }