From 596ee54021774f6c0dbf23fb7c1c0e18f6462ca3 Mon Sep 17 00:00:00 2001 From: Hernan Soberon Date: Thu, 21 Nov 2024 06:38:13 -0500 Subject: [PATCH] direct cast of string currency --- src/Utility/MoneyUtil.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Utility/MoneyUtil.php b/src/Utility/MoneyUtil.php index eca7137..498d955 100644 --- a/src/Utility/MoneyUtil.php +++ b/src/Utility/MoneyUtil.php @@ -116,7 +116,7 @@ protected static function loadMoneyFormatter(Currency $currency): MoneyFormatter throw new RuntimeException( sprintf( 'Cannot format currency \'%s\'. Only ISO currencies and Bitcoin are allowed.', - $currency + (string) $currency ) ); }