From 0735cb65f0fef90dd8bb32678a5000cdb55f123c Mon Sep 17 00:00:00 2001 From: lunar-mining Date: Wed, 19 Jan 2022 13:19:40 +0100 Subject: [PATCH] map: fixed typo in connect addr --- bin/ircd/src/program_options.rs | 1 - bin/map/src/main.rs | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/bin/ircd/src/program_options.rs b/bin/ircd/src/program_options.rs index 43ff120e0..c4de30f6b 100644 --- a/bin/ircd/src/program_options.rs +++ b/bin/ircd/src/program_options.rs @@ -73,7 +73,6 @@ impl ProgramOptions { ([127, 0, 0, 1], 6667).into() }; - let rpc_listen_addr = if let Some(rpc_addr) = app.value_of("RPC_LISTEN") { rpc_addr.parse()? } else { diff --git a/bin/map/src/main.rs b/bin/map/src/main.rs index 1f62b5f31..6b894134f 100644 --- a/bin/map/src/main.rs +++ b/bin/map/src/main.rs @@ -51,8 +51,8 @@ impl Map { } } - // --> {"jsonrpc": "2.0", "method": "say_hello", "params": [], "id": 42} - // <-- {"jsonrpc": "2.0", "result": "hello world", "id": 42} + //--> {"jsonrpc": "2.0", "method": "say_hello", "params": [], "id": 42} + //<-- {"jsonrpc": "2.0", "result": "hello world", "id": 42} async fn say_hello(&self) -> Result { let req = jsonrpc::request(json!("say_hello"), json!([])); Ok(self.request(req).await?) @@ -60,7 +60,7 @@ impl Map { } async fn start() -> Result<()> { - let client = Map::new("127.0.0.1:8000".to_string()); + let client = Map::new("tcp://127.0.0.1:8000".to_string()); let reply = client.say_hello().await?; println!("Server replied: {}", &reply.to_string()); Ok(())