Fix psalm errors

This commit is contained in:
dinamiko 2022-03-04 12:08:39 +01:00
parent dcbac3cae3
commit e8c2147762

View file

@ -227,7 +227,11 @@ class AuthorizedPaymentsProcessor {
)
);
if ( $this->config->has( 'intent' ) && strtoupper( (string) $this->config->get( 'intent' ) ) === 'CAPTURE' ) {
if (
$this->config->has( 'intent' )
&& strtoupper( (string) $this->config->get( 'intent' ) ) === 'CAPTURE'
&& is_array( $wc_orders )
) {
foreach ( $wc_orders as $wc_order ) {
if (
$this->subscription_helper->has_subscription( $wc_order->get_id() )