From 53713f5f2d4aee26d60938ae4d0847d1537b46f3 Mon Sep 17 00:00:00 2001 From: Aditya Kulkarni Date: Sat, 19 Oct 2019 20:22:03 -0700 Subject: [PATCH] Don't return json from GRPC --- lib/src/grpcconnector.rs | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/lib/src/grpcconnector.rs b/lib/src/grpcconnector.rs index 0f22c67..3a63b4e 100644 --- a/lib/src/grpcconnector.rs +++ b/lib/src/grpcconnector.rs @@ -4,8 +4,6 @@ use std::sync::{Arc}; use std::net::ToSocketAddrs; use std::net::SocketAddr; -use json::object; - use futures::{Future}; use futures::stream::Stream; @@ -286,11 +284,7 @@ pub fn broadcast_raw_tx(uri: &http::Uri, no_cert: bool, tx_bytes: Box<[u8]>) -> txid = txid[1..txid.len()-1].to_string(); } - let r = object!{ - "result" => "success", - "txid" => txid, - }; - Ok(r.pretty(2)) + Ok(txid) } else { Err(format!("Error: {:?}", sendresponse)) }