Browse Source

qt new_channel_dialog: fix regression: oepn chan with "max" amt

```
E | gui.qt.exception_window.Exception_Hook | exception caught by crash reporter
Traceback (most recent call last):
  File "...\electrum\electrum\gui\qt\channels_list.py", line 377, in new_channel_with_warning
	self.new_channel_dialog()
  File "...\electrum\electrum\gui\qt\channels_list.py", line 399, in new_channel_dialog
	return d.run()
  File "...\electrum\electrum\gui\qt\new_channel_dialog.py", line 133, in run
	if self.min_amount_sat and funding_sat < self.min_amount_sat:
TypeError: '<' not supported between instances of 'str' and 'int'
```
patch-4
SomberNight 3 years ago
parent
commit
ad42de03ac
No known key found for this signature in database GPG Key ID: B33B5F232C6271E9
  1. 7
      electrum/gui/qt/new_channel_dialog.py

7
electrum/gui/qt/new_channel_dialog.py

@ -130,9 +130,10 @@ class NewChannelDialog(WindowModalDialog):
funding_sat = self.amount_e.get_amount()
if not funding_sat:
return
if self.min_amount_sat and funding_sat < self.min_amount_sat:
self.window.show_error(_('Amount too low'))
return
if funding_sat != '!':
if self.min_amount_sat and funding_sat < self.min_amount_sat:
self.window.show_error(_('Amount too low'))
return
if self.network.channel_db:
connect_str = str(self.remote_nodeid.text()).strip()
else:

Loading…
Cancel
Save