fixed currency

This commit is contained in:
Edward Yang 2022-07-29 12:02:59 +08:00
parent e3abd5e7fb
commit 2120581011
1 changed files with 4 additions and 1 deletions

View File

@ -195,9 +195,12 @@ function locale(): string
* 货币格式化
*
* @param $price
* @param string $currency
* @param string $value
* @param bool $format
* @return string
*/
function currency_format($price, $currency = '', $value = '', $format = true): string
function currency_format($price, string $currency = '', string $value = '', bool $format = true): string
{
if (!$currency) {
$currency = Session::get('currency') ?? system_setting('base.currency');