Fix concurrent error handling for BTC provider
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
88552ba042
commit
43cd399c18
@ -55,8 +55,10 @@ func (p *Provider) GetBalances() ([]int, []string, error) {
|
||||
defer wg.Done()
|
||||
addressResponse, err := p.client.getAddress(bitcoinAddress)
|
||||
if err != nil {
|
||||
err := fmt.Errorf("failed to get bitcoin address '%s': %v", bitcoinAddress, err)
|
||||
goErr = &err
|
||||
err := fmt.Errorf("failed to get BTC balance for bitcoin address '%s': %v", bitcoinAddress, err)
|
||||
if err != nil {
|
||||
goErr = &err
|
||||
}
|
||||
return
|
||||
}
|
||||
satoshiBalance += addressResponse.ChainStats.FundedTxoSum - addressResponse.ChainStats.SpentTxoSum
|
||||
|
Loading…
x
Reference in New Issue
Block a user