Skip to content
This repository has been archived by the owner on Dec 7, 2023. It is now read-only.

Fix relay tx #594

Merged
merged 1 commit into from
May 27, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion neo-cli/CLI/MainService.Network.cs
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ private void OnRelayCommand(JObject jsonObjectToRelay)
return;
}
tx.Witnesses = context.GetWitnesses();
NeoSystem.LocalNode.Tell(new LocalNode.Relay { Inventory = tx });
NeoSystem.Blockchain.Tell(tx);
Console.WriteLine($"Data relay success, the hash is shown as follows:{Environment.NewLine}{tx.Hash}");
}
catch (Exception e)
Expand Down
4 changes: 2 additions & 2 deletions neo-cli/CLI/MainService.Wallet.cs
Original file line number Diff line number Diff line change
Expand Up @@ -432,7 +432,7 @@ private void OnSendCommand(UInt160 asset, UInt160 to, string amount)
if (context.Completed)
{
tx.Witnesses = context.GetWitnesses();
NeoSystem.LocalNode.Tell(new LocalNode.Relay { Inventory = tx });
NeoSystem.Blockchain.Tell(tx);
Console.WriteLine($"TXID: {tx.Hash}");
}
else
Expand Down Expand Up @@ -534,7 +534,7 @@ private void SignAndSendTx(Transaction tx)
{
tx.Witnesses = context.GetWitnesses();

NeoSystem.LocalNode.Tell(new LocalNode.Relay { Inventory = tx });
NeoSystem.Blockchain.Tell(tx);

msg = $"Signed and relayed transaction with hash={tx.Hash}";
Console.WriteLine(msg);
Expand Down