mirror of
https://github.com/lightninglabs/pool.git
synced 2026-08-17 13:06:52 +02:00
Merge pull request #200 from wpaulino/delete-pending-batch-after-replacement
rpc: delete previous pending batch after receiving replacement
This commit is contained in:
commit
2ee7d8a74f
1 changed files with 10 additions and 0 deletions
10
rpcserver.go
10
rpcserver.go
|
|
@ -388,6 +388,16 @@ func (s *rpcServer) handleServerMessage(rpcMsg *poolrpc.ServerAuctionMessage) er
|
|||
"artifacts: %v", err)
|
||||
return s.sendRejectBatch(batch, err)
|
||||
}
|
||||
|
||||
// Clear our staging area for the new batch proposal. We
|
||||
// consider any errors as a hard failure and reject the
|
||||
// batch.
|
||||
err = s.server.fundingManager.DeletePendingBatch()
|
||||
if err != nil {
|
||||
rpcLog.Errorf("Error clearing previous "+
|
||||
"pending batch: %v", err)
|
||||
return s.sendRejectBatch(batch, err)
|
||||
}
|
||||
}
|
||||
|
||||
// Do an in-depth verification of the batch.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue