• Resolved Pat

    (@patrickhaond)


    Hi there.

    I am trying to use your plugin on a new WooCommerce website and it seems teh Cart Page always causes an error.

    Fatal error: Uncaught TypeError: WooCommerce\PayPalCommerce\WcGateway\Helper\SettingsStatus::is_smart_button_enabled_for_location(): Argument #1 ($location) must be of type string, null given, called in /htdocs/wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-blocks/src/PayPalPaymentMethod.php on line 239 and defined in /htdocs/wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-wc-gateway/src/Helper/SettingsStatus.php:87 Stack trace: #0 /htdocs/wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-blocks/src/PayPalPaymentMethod.php(239): WooCommerce\PayPalCommerce\WcGateway\Helper\SettingsStatus->is_smart_button_enabled_for_location(NULL) #1 /htdocs/wp-content/plugins/woocommerce/src/Blocks/Payments/PaymentMethodRegistry.php(62): WooCommerce\PayPalCommerce\Blocks\PayPalPaymentMethod->get_payment_method_data() #2 /htdocs/wp-content/plugins/woocommerce/src/Blocks/Payments/Api.php(92): Automattic\WooCommerce\Blocks\Payments\PaymentMethodRegistry->get_all_registered_script_data() #3 /htdocs/wp-includes/class-wp-hook.php(324): Automattic\WooCommerce\Blocks\Payments\Api->add_payment_method_script_data('') #4 /htdocs/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array) #5 /htdocs/wp-includes/plugin.php(517): WP_Hook->do_action(Array) #6 /htdocs/wp-content/plugins/woocommerce/src/Blocks/BlockTypes/Cart.php(261): do_action('woocommerce_blo...') #7 /htdocs/wp-content/plugins/woocommerce/src/Blocks/BlockTypes/AbstractBlock.php(416): Automattic\WooCommerce\Blocks\BlockTypes\Cart->enqueue_data(Array) #8 /htdocs/wp-content/plugins/woocommerce/src/Blocks/BlockTypes/Cart.php(147): Automattic\WooCommerce\Blocks\BlockTypes\AbstractBlock->enqueue_assets(Array, '\n<div class="wp...', Object(WP_Block)) #9 /htdocs/wp-content/plugins/woocommerce/src/Blocks/BlockTypes/AbstractBlock.php(96): Automattic\WooCommerce\Blocks\BlockTypes\Cart->enqueue_assets(Array, '\n<div class="wp...', Object(WP_Block)) #10 /htdocs/wp-includes/class-wp-block.php(519): Automattic\WooCommerce\Blocks\BlockTypes\AbstractBlock->render_callback(Array, '\n<div class="wp...', Object(WP_Block)) #11 /htdocs/wp-includes/blocks.php(2061): WP_Block->render() #12 /htdocs/wp-includes/blocks.php(2113): render_block(Array) #13 /htdocs/wp-includes/class-wp-hook.php(324): do_blocks('<!-- wp:woocomm...') #14 /htdocs/wp-includes/plugin.php(205): WP_Hook->apply_filters('<!-- wp:woocomm...', Array) #15 /htdocs/wp-includes/post-template.php(256): apply_filters('the_content', '<!-- wp:woocomm...') #16 /htdocs/wp-content/themes/Divi/page.php(46): the_content() #17 /htdocs/wp-includes/template-loader.php(106): include('/htdocs/wp-cont...') #18 /htdocs/wp-blog-header.php(19): require_once('/htdocs/wp-incl...') #19 /htdocs/index.php(17): require('/htdocs/wp-blog...') #20 {main} thrown in?/htdocs/wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-wc-gateway/src/Helper/SettingsStatus.php?on line?87

    Thank you for any help.

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Femi

    (@femiyb)

    Hello @patrickhaond

    We have not received similar reports of this issue.

    I suggest performing a conflict test to rule out eventual issues with the theme or a different plugin. We recommend temporarily activating the default theme Storefront and disabling all other plugins except for?WooCommerce and?PayPal Payments to see if the behavior persists.

    Here’s a guide that explains the steps in more detail: How to test for conflicts
    Please let us know how this works out for you.

    Regards,
    Femi.

    Thread Starter Pat

    (@patrickhaond)

    Thank you for the answer.
    It doesn’t look like any conflict.
    Actually I updated your plugin and the error was solved, so it seems to be plugin problem.

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.