Folders and files are now deleted more comprehensively
This commit is contained in:
parent
7147f16042
commit
ace4bed0c6
13 changed files with 253 additions and 103 deletions
|
|
@ -19,7 +19,7 @@ struct CustomStorage {
|
|||
impl StorageFactory for CustomStorageFactory {
|
||||
type Storage = CustomStorage;
|
||||
|
||||
fn init_storage(&self, _info: &librqbit::ManagedTorrentInfo) -> anyhow::Result<Self::Storage> {
|
||||
fn create(&self, _info: &librqbit::ManagedTorrentInfo) -> anyhow::Result<Self::Storage> {
|
||||
Ok(CustomStorage::default())
|
||||
}
|
||||
|
||||
|
|
@ -48,6 +48,14 @@ impl TorrentStorage for CustomStorage {
|
|||
fn take(&self) -> anyhow::Result<Box<dyn TorrentStorage>> {
|
||||
anyhow::bail!("not implemented")
|
||||
}
|
||||
|
||||
fn remove_directory_if_empty(&self, _path: &std::path::Path) -> anyhow::Result<()> {
|
||||
anyhow::bail!("not implemented")
|
||||
}
|
||||
|
||||
fn init(&mut self, _meta: &librqbit::ManagedTorrentInfo) -> anyhow::Result<()> {
|
||||
anyhow::bail!("not implemented")
|
||||
}
|
||||
}
|
||||
|
||||
#[tokio::main]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue