1
0

qt: trustedcoin: only allow signing with broadcast

Only allow signing a transaction if it also gets broadcast by disabling
the signing and broadcast button of the preview dialog when creating a
new tx. Makes it slightly less trivial to cheat with the fees.
This commit is contained in:
f321x
2025-12-16 13:54:08 +01:00
parent 5e53f82bc6
commit a105c50029

View File

@@ -370,7 +370,13 @@ class SendTab(QWidget, MessageBoxMixin, Logger):
tx.swap_payment_hash = swap.payment_hash
if is_preview:
self.window.show_transaction(tx, external_keypairs=external_keypairs, invoice=invoice)
self.window.show_transaction(
tx,
external_keypairs=external_keypairs,
invoice=invoice,
show_sign_button=self.wallet.wallet_type != '2fa',
show_broadcast_button=self.wallet.wallet_type != '2fa',
)
return
self.save_pending_invoice()
def sign_done(success):