mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-11-12 23:28:31 +01:00
lnd: fix gosimple warnings
This commit is contained in:
committed by
Olaoluwa Osuntokun
parent
f5fd4138a0
commit
8fb54782e2
@@ -311,17 +311,14 @@ func loadTestCredits(miner *rpctest.Harness, w *lnwallet.LightningWallet, numOut
|
||||
// Wait until the wallet has finished syncing up to the main chain.
|
||||
ticker := time.NewTicker(100 * time.Millisecond)
|
||||
expectedBalance := btcutil.Amount(satoshiPerOutput * int64(numOutputs))
|
||||
out:
|
||||
for {
|
||||
select {
|
||||
case <-ticker.C:
|
||||
balance, err := w.ConfirmedBalance(1, false)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if balance == expectedBalance {
|
||||
break out
|
||||
}
|
||||
|
||||
for range ticker.C {
|
||||
balance, err := w.ConfirmedBalance(1, false)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if balance == expectedBalance {
|
||||
break
|
||||
}
|
||||
}
|
||||
ticker.Stop()
|
||||
|
||||
Reference in New Issue
Block a user