Skip to content

Commit b05f3ca

Browse files
authored
fix: continue instead of return during auto swap check (#1537)
1 parent 63f4188 commit b05f3ca

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

swaps/swaps_service.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -199,13 +199,13 @@ func (svc *swapsService) EnableAutoSwapOut() error {
199199
balance, err := svc.lnClient.GetBalances(ctx, false)
200200
if err != nil {
201201
logger.Logger.WithError(err).Error("Failed to get balance")
202-
return
202+
continue
203203
}
204204
lightningBalance := uint64(balance.Lightning.TotalSpendable)
205205
balanceThresholdMilliSats := balanceThreshold * 1000
206206
if lightningBalance < balanceThresholdMilliSats {
207207
logger.Logger.Info("Threshold requirements not met for swap, ignoring")
208-
return
208+
continue
209209
}
210210
logger.Logger.WithFields(logrus.Fields{
211211
"amount": amount,

0 commit comments

Comments
 (0)