updated error handling
This commit is contained in:
parent
bb0a272d0f
commit
a6f5a44c6a
@ -71,12 +71,13 @@ pub async fn run() {
|
||||
hostname: gethostname(true),
|
||||
ipdata: ip_to_send,
|
||||
};
|
||||
let status = send_to_ipbl_websocket(&mut wssocketrr, &ipe).await;
|
||||
if !status {
|
||||
if !send_to_ipbl_websocket(&mut wssocketrr, &ipe).await {
|
||||
drop(ctx);
|
||||
wssocketrr = websocketreqrep(&ctxwsrr).await;
|
||||
continue;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
continue
|
||||
}
|
||||
|
||||
@ -96,6 +97,7 @@ pub async fn run() {
|
||||
send_to_ipbl_api(&ctx.client, &ctx.flags.server, &ipe).await;
|
||||
let status = send_to_ipbl_websocket(&mut wssocketrr, &ipe).await;
|
||||
if !status {
|
||||
drop(ctx);
|
||||
wssocketrr = websocketreqrep(&ctxwsrr).await;
|
||||
continue;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user