mirror of
https://github.com/LBRYFoundation/LBRY-Vault.git
synced 2025-09-04 21:05:11 +00:00
ln channel open: save funding tx as local tx into wallet
This commit is contained in:
parent
30dcab0877
commit
5c9bd2d2b4
1 changed files with 2 additions and 0 deletions
|
@ -826,6 +826,8 @@ class LNWallet(LNWorker):
|
|||
self.save_channel(chan)
|
||||
self.lnwatcher.add_channel(chan.funding_outpoint.to_str(), chan.get_funding_address())
|
||||
self.network.trigger_callback('channels_updated', self.wallet)
|
||||
self.wallet.add_transaction(funding_tx) # save tx as local into the wallet
|
||||
self.wallet.set_label(funding_tx.txid(), _('Open channel'))
|
||||
if funding_tx.is_complete():
|
||||
# TODO make more robust (timeout low? server returns error?)
|
||||
await asyncio.wait_for(self.network.broadcast_transaction(funding_tx), LN_P2P_NETWORK_TIMEOUT)
|
||||
|
|
Loading…
Add table
Reference in a new issue