Fatal error in Multi-Currency Storefront integration #6697
Labels
category: core
WC Payments core related issues, where it’s obvious.
component: customer multi-currency
Issues related to customer multi-currency project
priority: low
The issue/PR is low priority—not many people are affected or there’s a workaround, etc.
type: bug
The issue is a confirmed bug.
Describe the bug
Originally reported here: p1687948619961739-slack-C01B8KNUYSW
Unsure how to replicate this, as this should not be able to happen. The
get_switcher_widget_markup
method is being called, which calls theget_currency_switcher_widget
method, and that is returningcurrency_switcher_widget
as anull
property. This property should only benull
up to the point where thewidgets_init
hook is called, which is before the theme template files are called.The only fix I can think of is to call the
init_widgets
method again if thecurrency_switcher_widget
property isnull
whenget_currency_switcher_widget
is called.The text was updated successfully, but these errors were encountered: