Use get_woocommerce_currency to get shop currency

This commit is contained in:
dinamiko 2022-02-11 10:47:36 +01:00
parent df57609350
commit 19b6eebd3e

View file

@ -326,11 +326,7 @@ return array(
'api.shop.currency' => static function ( ContainerInterface $container ) : string {
$currency = get_woocommerce_currency();
if ( $currency ) {
return $currency;
}
$currency = get_option( 'woocommerce_currency' );
if ( ! $currency ) {
return 'NO_CURRENCY'; // Unlikely to happen.
}