kill some bs58 (#4316)

* kill some bs58

* fixup
This commit is contained in:
Rob Walker
2019-05-16 21:43:18 -07:00
committed by GitHub
parent 41156da4ca
commit 39e85a3e53
4 changed files with 17 additions and 29 deletions

View File

@ -35,10 +35,7 @@ fn test_rpc_send_tx() {
.send()
.unwrap();
let json: Value = serde_json::from_str(&response.text().unwrap()).unwrap();
let blockhash_vec = bs58::decode(json["result"][0].as_str().unwrap())
.into_vec()
.unwrap();
let blockhash = Hash::new(&blockhash_vec);
let blockhash: Hash = json["result"][0].as_str().unwrap().parse().unwrap();
info!("blockhash: {:?}", blockhash);
let tx = system_transaction::transfer(&alice, &bob_pubkey, 20, blockhash, 0);