This commit is contained in:
Pedro Silva 2024-01-17 13:44:00 +00:00
parent b31274efb0
commit b0e47f4460
No known key found for this signature in database
GPG key ID: E2EE20C0669D24B3

View file

@ -190,7 +190,7 @@ class WcSubscriptionsModule implements ModuleInterface {
function ( $payment_method_to_display, $subscription, $context ) {
$payment_gateway = wc_get_payment_gateway_by_order( $subscription );
if ( $payment_gateway && $payment_gateway->id === PayPalGateway::ID ) {
if ( $payment_gateway instanceof \WC_Payment_Gateway && $payment_gateway->id === PayPalGateway::ID ) {
return $subscription->get_payment_method_title( $context );
}