Added --exit-on-download option, only works without the server so far

This commit is contained in:
Igor Katson 2023-07-10 11:24:30 +01:00
parent af30affb37
commit a800048b7e
No known key found for this signature in database
GPG key ID: B4EC22B66D61A3F5
4 changed files with 37 additions and 7 deletions

View file

@ -140,9 +140,8 @@ impl TorrentManagerHandle {
todo!()
}
pub async fn wait_until_completed(&self) -> anyhow::Result<()> {
loop {
tokio::time::sleep(Duration::from_secs(60)).await;
}
self.manager.state.wait_until_completed().await;
Ok(())
}
}