Skip to content

Commit

Permalink
Fix missing currency
Browse files Browse the repository at this point in the history
  • Loading branch information
pgrimaud committed Dec 30, 2023
1 parent a5a6012 commit ef2ee07
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Bitcoin/Bitcoin.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public function __construct(
public function getPrice(string $exchange = null, string $currency = null): int
{
$exchange ??= $this->exchange->getName();
$currency ??= $this->exchange->getCurrency();
$currency = !empty($this->exchange->getCurrency()) ? $this->exchange->getCurrency() : 'USD';

$redisKey = 'lametric:bitcoin:' . $this->exchange->getName() . ':' . strtolower($currency);

Expand Down

0 comments on commit ef2ee07

Please sign in to comment.