diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/main.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/main.rs b/src/main.rs index ad15301..bd279e1 100644 --- a/src/main.rs +++ b/src/main.rs @@ -76,14 +76,14 @@ async fn fetch_url(url: hyper::Uri) -> Result<Response<Incoming>> { Ok(sender.send_request(req).await?) } -fn get_request_target_uri() -> Uri { - env::var("REQUEST_TO") +fn get_space_open_request_target_uri() -> Uri { + env::var("OPEN_REQUEST_TO") .unwrap_or("http://10.0.0.77:8080/".to_string()) .parse::<hyper::Uri>() .unwrap() } async fn get_is_open() -> Result<bool> { - let mut res = fetch_url(get_request_target_uri()).await?; + let mut res = fetch_url(get_space_open_request_target_uri()).await?; let mut out = "".to_string(); while let Some(next) = res.frame().await { @@ -163,8 +163,8 @@ async fn main() -> Result<()> { println!( "Listening on: LISTEN_ON={addr:#?} -Sending fetch requests to: REQUEST_TO={:#?}", - get_request_target_uri() +Sending fetch requests to: OPEN_REQUEST_TO={:#?}", + get_space_open_request_target_uri() ); // We start a loop to continuously accept incoming connections |