diff --git a/src/neo/Wallets/Wallet.cs b/src/neo/Wallets/Wallet.cs index e353ef85da..b465f396f7 100644 --- a/src/neo/Wallets/Wallet.cs +++ b/src/neo/Wallets/Wallet.cs @@ -448,6 +448,7 @@ public bool Sign(ContractParametersContext context) if (fSuccess) m--; if (context.Completed || m <= 0) break; } + continue; } else if (account.HasKey) { @@ -455,25 +456,24 @@ public bool Sign(ContractParametersContext context) KeyPair key = account.GetKey(); byte[] signature = context.Verifiable.Sign(key); fSuccess |= context.AddSignature(account.Contract, key.PublicKey, signature); + continue; } } - else - { - // Try Smart contract verification - using var snapshot = Blockchain.Singleton.GetSnapshot(); - var contract = snapshot.Contracts.TryGet(scriptHash); + // Try Smart contract verification - if (contract != null) - { - var deployed = new DeployedContract(contract); + using var snapshot = Blockchain.Singleton.GetSnapshot(); + var contract = snapshot.Contracts.TryGet(scriptHash); - // Only works with verify without parameters + if (contract != null) + { + var deployed = new DeployedContract(contract); - if (deployed.ParameterList.Length == 0) - { - fSuccess |= context.Add(deployed); - } + // Only works with verify without parameters + + if (deployed.ParameterList.Length == 0) + { + fSuccess |= context.Add(deployed); } } }