Skip to content

Commit

Permalink
funding: decouple funding wait from fundingLocked and chanAnn
Browse files Browse the repository at this point in the history
This commit decouples the wait for funding transaction confirmations
in the waitForFundingConfirmation function from the announcement of
the channel in the sendFundingLockedAndAnnounceChannel function.
Additionally, the sendFundingLockedAndAnnounceChannel function is
now decoupled into the sendFundingLocked and sendChannelAnnouncement
functions.
  • Loading branch information
nsa committed Sep 13, 2017
1 parent e004e10 commit dd77c4f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions fundingmanager.go
Original file line number Diff line number Diff line change
Expand Up @@ -1173,14 +1173,14 @@ func (f *fundingManager) handleFundingCreated(fmsg *fundingCreatedMsg) {
}
defer lnChannel.Stop()

if err = f.sendFundingLocked(completeChan, lnChannel,
shortChanID); err != nil {
err = f.sendFundingLocked(completeChan, lnChannel, shortChanID);
if err != nil {
fndgLog.Errorf("Failed to send fundingLocked: %v", err)
return
}

if err = f.sendChannelAnnouncement(completeChan, lnChannel,
shortChanID); err != nil {
err = f.sendChannelAnnouncement(completeChan, lnChannel, shortChanID);
if err != nil {
fndgLog.Errorf("Failed to send channel " +
"announcement: %v", err)
return
Expand Down

0 comments on commit dd77c4f

Please sign in to comment.