Skip to content

Commit

Permalink
Improve logging when currency is missing
Browse files Browse the repository at this point in the history
  • Loading branch information
patrick-ogrady committed Jul 15, 2020
1 parent 48272b8 commit c249946
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion reconciler/reconciler.go
Original file line number Diff line number Diff line change
Expand Up @@ -764,7 +764,12 @@ func GetCurrencyBalance(

liveAmount, err := ExtractAmount(liveBalances, currency)
if err != nil {
return nil, "", err
return nil, "", fmt.Errorf(
"%w: could not get %s currency balance for %s",
err,
types.PrettyPrintStruct(currency),
types.PrettyPrintStruct(account),
)
}

return liveBlock, liveAmount.Value, nil
Expand Down

0 comments on commit c249946

Please sign in to comment.