• File: class-woocommerce-gateway-affirm.php
    Method: woocommerce_single_product_summary

    Check if ( ! $product->is_type( $supported_types ) ) doesn’t exclude types like “variable-subscription”. You need to find a better way to omit showing Affirm notes on subscription product pages.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter MisterR

    (@mister_r)

    In other words, $product->is_type('variable') is also true for variable subscriptions.

    Thread Starter MisterR

    (@mister_r)

    For those who need a quick fix:

    function stv_wc_gateway_affirm_supported_product_types($types){
    global $product;
    if ($product->is_type('variable-subscription'))
    $types = array_diff($types, array('variable'));
    return $types;
    }
    add_filter('wc_gateway_affirm_supported_product_types', 'stv_wc_gateway_affirm_supported_product_types', 20);

    • This reply was modified 6 months, 3 weeks ago by MisterR.
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Affirm notes are shown on variable subscription product pages’ is closed to new replies.