@@ -1341,7 +1341,7 @@ func (b *Batcher) monitorSpendAndNotify(ctx context.Context, sweeps []*sweep,
1341
1341
1342
1342
// monitorConfAndNotify monitors the confirmation of a specific transaction and
1343
1343
// writes the response back to the response channel. It is called if the batch
1344
- // is reorg-safely confirmed and we just need to deliver the data back to the
1344
+ // is reorg-safely confirmed, and we just need to deliver the data back to the
1345
1345
// caller though SpendNotifier.
1346
1346
func (b * Batcher ) monitorConfAndNotify (ctx context.Context , sweep * sweep ,
1347
1347
notifier * SpendNotifier , spendTx * wire.MsgTx ,
@@ -1354,9 +1354,8 @@ func (b *Batcher) monitorConfAndNotify(ctx context.Context, sweep *sweep,
1354
1354
1355
1355
batchTxid := spendTx .TxHash ()
1356
1356
1357
- if len (spendTx .TxOut ) != 1 {
1358
- return fmt .Errorf ("unexpected number of outputs in batch: %d, " +
1359
- "want %d" , len (spendTx .TxOut ), 1 )
1357
+ if len (spendTx .TxOut ) < 1 {
1358
+ return fmt .Errorf ("expected at least one output in batch" )
1360
1359
}
1361
1360
batchPkScript := spendTx .TxOut [0 ].PkScript
1362
1361
@@ -1426,7 +1425,7 @@ func (b *Batcher) writeToErrChan(ctx context.Context, err error) {
1426
1425
1427
1426
// convertSweep converts a fetched sweep from the database to a sweep that is
1428
1427
// ready to be processed by the batcher. It loads swap from loopdb by calling
1429
- // method FetchLoopOutSwap.
1428
+ // the method FetchLoopOutSwap.
1430
1429
func (b * Batcher ) convertSweep (ctx context.Context , dbSweep * dbSweep ) (
1431
1430
* sweep , error ) {
1432
1431
0 commit comments