Skip to content

Commit

Permalink
Fix codeclimate: Avoid using undefined variables such as '' which wil…
Browse files Browse the repository at this point in the history
…l lead to PHP notices
  • Loading branch information
jimmerioles committed Dec 3, 2024
1 parent 8ec3b0b commit 7b1b057
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/Provider/BitpayProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ class BitpayProvider extends AbstractProvider
protected function parseToExchangeRatesArray($rawJsonData)
{
$arrayData = json_decode($rawJsonData, true);
$exchangeRatesArray = [];

foreach ($arrayData as $data) {
$exchangeRatesArray[$data['code']] = $data['rate'];
Expand Down
1 change: 1 addition & 0 deletions src/Provider/CoindeskProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ class CoindeskProvider extends AbstractProvider
protected function parseToExchangeRatesArray($rawJsonData)
{
$arrayData = json_decode($rawJsonData, true);
$exchangeRatesArray = [];

foreach ($arrayData['bpi'] as $value) {
$exchangeRatesArray[$value['code']] = $value['rate_float'];
Expand Down

0 comments on commit 7b1b057

Please sign in to comment.