From 2548e77d90060c46a886efdcc85e74e6066d323d Mon Sep 17 00:00:00 2001 From: Craig Raw Date: Wed, 29 Sep 2021 10:32:43 +0200 Subject: [PATCH] followup to disable adding accounts to p2sh legacy multisig --- .../com/sparrowwallet/sparrow/wallet/SettingsController.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/sparrowwallet/sparrow/wallet/SettingsController.java b/src/main/java/com/sparrowwallet/sparrow/wallet/SettingsController.java index 271d50dd..be8a6787 100644 --- a/src/main/java/com/sparrowwallet/sparrow/wallet/SettingsController.java +++ b/src/main/java/com/sparrowwallet/sparrow/wallet/SettingsController.java @@ -255,7 +255,7 @@ public class SettingsController extends WalletFormController implements Initiali scanDescriptorQR.setVisible(!walletForm.getWallet().isValid()); export.setDisable(!walletForm.getWallet().isValid()); - addAccount.setDisable(!walletForm.getWallet().isValid()); + addAccount.setDisable(!walletForm.getWallet().isValid() || walletForm.getWallet().getScriptType() == ScriptType.P2SH); revert.setDisable(true); apply.setDisable(true); } @@ -563,7 +563,7 @@ public class SettingsController extends WalletFormController implements Initiali public void walletSettingsChanged(WalletSettingsChangedEvent event) { if(event.getWalletId().equals(walletForm.getWalletId())) { export.setDisable(!event.getWallet().isValid()); - addAccount.setDisable(!event.getWallet().isValid()); + addAccount.setDisable(!event.getWallet().isValid() || event.getWallet().getScriptType() == ScriptType.P2SH); scanDescriptorQR.setVisible(!event.getWallet().isValid()); } }