Skip to content

Commit

Permalink
fixed bug
Browse files Browse the repository at this point in the history
  • Loading branch information
chenzhitong committed Aug 1, 2024
1 parent d072b4d commit 206a853
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
3 changes: 1 addition & 2 deletions src/neoxp/Commands/BatchCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -290,8 +290,7 @@ await txExec.TransferNFTAsync(
await writer.WriteLineAsync($"Created Wallet {cmd.Model.Name}");
for (int x = 0; x < wallet.Accounts.Count; x++)
{
var address = UInt160.Parse(wallet.Accounts[x].ScriptHash).ToAddress(ProtocolSettings.Default.AddressVersion);
await writer.WriteLineAsync($" Address: {address}");
await writer.WriteLineAsync($" Address: {wallet.Accounts[x].ScriptHash}");
}
break;
}
Expand Down
3 changes: 1 addition & 2 deletions src/neoxp/Commands/PolicyCommand.IsBlocked.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@ internal async Task<int> OnExecuteAsync(CommandLineApplication app, IConsole con
}

var isBlocked = await expressNode.GetIsBlockedAsync(scriptHash.AsT0).ConfigureAwait(false);
var address = UInt160.Parse(ScriptHash).ToAddress(ProtocolSettings.Default.AddressVersion);
await console.Out.WriteLineAsync($"Account is {(isBlocked ? "" : "not ")}blocked. Address: {address}, scripthash: {scriptHash}");
await console.Out.WriteLineAsync($"{ScriptHash} account is {(isBlocked ? "" : "not ")}blocked");
return 0;
}
catch (Exception ex)
Expand Down
3 changes: 1 addition & 2 deletions src/neoxp/Commands/WalletCommand.Create.cs
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,7 @@ internal int OnExecute(CommandLineApplication app, IConsole console)

for (int i = 0; i < wallet.Accounts.Count; i++)
{
var address = UInt160.Parse(wallet.Accounts[i].ScriptHash).ToAddress(ProtocolSettings.Default.AddressVersion);
console.WriteLine($" Address: {address}");
console.WriteLine($" Address: {wallet.Accounts[i].ScriptHash}");
}

console.WriteLine("\n\x1b[33mNote: The private keys for the accounts in this wallet are *not* encrypted.\x1b[0m");
Expand Down

0 comments on commit 206a853

Please sign in to comment.