mirror of
https://codeberg.org/icewind/tasproxy.git
synced 2026-06-03 18:24:08 +02:00
logging
This commit is contained in:
parent
ff085e85ed
commit
ac97671919
1 changed files with 3 additions and 0 deletions
|
|
@ -60,11 +60,14 @@ async fn main() -> Result<()> {
|
||||||
.or_else(|| states.get(&requested_device.replace('-', "_")))
|
.or_else(|| states.get(&requested_device.replace('-', "_")))
|
||||||
{
|
{
|
||||||
if let Some(ip) = state.ip {
|
if let Some(ip) = state.ip {
|
||||||
|
println!("{} => {}", requested_device, ip);
|
||||||
Ok((format!("http://{}", ip), String::new()))
|
Ok((format!("http://{}", ip), String::new()))
|
||||||
} else {
|
} else {
|
||||||
|
eprintln!("Error {} has no ip set", requested_device);
|
||||||
Err(warp::reject::not_found())
|
Err(warp::reject::not_found())
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
eprintln!("Error {} has no discovered", requested_device);
|
||||||
Err(warp::reject::not_found())
|
Err(warp::reject::not_found())
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue