qt/kivy receive tab: show error msg when creating req with amt<dust
This commit is contained in:
@@ -508,6 +508,7 @@ class ReceiveScreen(CScreen):
|
|||||||
if amount_sat and amount_sat < self.app.wallet.dust_threshold():
|
if amount_sat and amount_sat < self.app.wallet.dust_threshold():
|
||||||
self.address = ''
|
self.address = ''
|
||||||
if not self.app.wallet.has_lightning():
|
if not self.app.wallet.has_lightning():
|
||||||
|
self.app.show_info(_('Amount too small to be received onchain'))
|
||||||
return
|
return
|
||||||
else:
|
else:
|
||||||
addr = self.address or self.app.wallet.get_unused_address()
|
addr = self.address or self.app.wallet.get_unused_address()
|
||||||
|
|||||||
@@ -325,6 +325,7 @@ class ReceiveTab(QWidget, MessageBoxMixin, Logger):
|
|||||||
if amount_sat and amount_sat < self.wallet.dust_threshold():
|
if amount_sat and amount_sat < self.wallet.dust_threshold():
|
||||||
address = None
|
address = None
|
||||||
if not self.wallet.has_lightning():
|
if not self.wallet.has_lightning():
|
||||||
|
self.show_error(_('Amount too small to be received onchain'))
|
||||||
return
|
return
|
||||||
else:
|
else:
|
||||||
address = self.get_bitcoin_address_for_request(amount_sat)
|
address = self.get_bitcoin_address_for_request(amount_sat)
|
||||||
|
|||||||
Reference in New Issue
Block a user