From a5a60121b0b9f292a7e8055ec6b7ed00740461d1 Mon Sep 17 00:00:00 2001 From: Pierre Grimaud Date: Thu, 3 Aug 2023 10:04:41 +0200 Subject: [PATCH] Fix default currency --- src/Bitcoin/Exchange.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Bitcoin/Exchange.php b/src/Bitcoin/Exchange.php index 3d2a580..f0dff4c 100644 --- a/src/Bitcoin/Exchange.php +++ b/src/Bitcoin/Exchange.php @@ -34,7 +34,7 @@ public function __construct(array $parameters = []) $exchange = strtolower($parameters['exchange'] ?? ''); $this->name = in_array($exchange, self::ALLOWED_EXCHANGES) ? $exchange : self::ALLOWED_EXCHANGES[0]; - $currency = $parameters['currency'] ?? ''; + $currency = $parameters['currency'] ?? 'USD'; $this->currency = $this->sanitizeCurrency($currency); $this->showPrice = !isset($parameters['bitcoin']) || (isset($parameters['bitcoin']) && ($parameters['bitcoin'] === 'true' || $parameters['bitcoin'] === ''));