Skip to content

Commit

Permalink
Put cancel token back in its place
Browse files Browse the repository at this point in the history
  • Loading branch information
durch committed Dec 4, 2024
1 parent bb483eb commit af74119
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion nym-network-monitor/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,6 @@ async fn main() -> Result<()> {
Ok(_) => {
info!("Received kill signal, shutting down, submitting final batch of metrics");
submit_metrics(client).await?;
cancel_token.cancel();
break;
}
Err(_) => {
Expand All @@ -232,6 +231,8 @@ async fn main() -> Result<()> {
};
}

cancel_token.cancel();

server_handle.await??;

Ok(())
Expand Down

0 comments on commit af74119

Please sign in to comment.