From 4003dfe2460187f7998a2da79fb2550a72c93d83 Mon Sep 17 00:00:00 2001 From: Mahesh Bansod Date: Sun, 7 Nov 2021 18:49:15 +0530 Subject: [PATCH] Added method to specify host of raw client --- rawclient/src/lib.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/rawclient/src/lib.rs b/rawclient/src/lib.rs index 068240c..326a251 100644 --- a/rawclient/src/lib.rs +++ b/rawclient/src/lib.rs @@ -39,6 +39,12 @@ pub fn new() -> Client { } } +pub fn with_host(host: &str) -> Client { + Client { + client: jsonrpc2_client::new(&host), + } +} + impl Client { pub async fn send_request( &self,