Browse Source

do not show freeze/unfreeze channel options if channel is closed

hard-fail-on-bad-server-string
ThomasV 5 years ago
parent
commit
bb35e330fb
  1. 3
      electrum/gui/qt/channels_list.py

3
electrum/gui/qt/channels_list.py

@ -145,7 +145,7 @@ class ChannelsList(MyTreeView):
cc = self.add_copy_menu(menu, idx)
cc.addAction(_("Long Channel ID"), lambda: self.place_text_on_clipboard(channel_id.hex(),
title=_("Long Channel ID")))
if not chan.is_closed():
if not chan.is_frozen_for_sending():
menu.addAction(_("Freeze (for sending)"), lambda: chan.set_frozen_for_sending(True))
else:
@ -155,7 +155,6 @@ class ChannelsList(MyTreeView):
else:
menu.addAction(_("Unfreeze (for receiving)"), lambda: chan.set_frozen_for_receiving(False))
funding_tx = self.parent.wallet.db.get_transaction(chan.funding_outpoint.txid)
if funding_tx:
menu.addAction(_("View funding transaction"), lambda: self.parent.show_transaction(funding_tx))

Loading…
Cancel
Save