Continuing refactor

This commit is contained in:
Igor Katson 2023-11-25 00:24:32 +00:00
parent 73e41ba7d5
commit 17b243921d
No known key found for this signature in database
GPG key ID: B4EC22B66D61A3F5
11 changed files with 395 additions and 64 deletions

View file

@ -447,12 +447,16 @@ impl ApiInternal {
}
fn api_torrent_action_forget(&self, idx: TorrentId) -> Result<EmptyJsonResponse> {
self.session.delete(idx, false)?;
self.session
.delete(idx, false)
.context("error forgetting torrent")?;
Ok(Default::default())
}
fn api_torrent_action_delete(&self, idx: TorrentId) -> Result<EmptyJsonResponse> {
self.session.delete(idx, true)?;
self.session
.delete(idx, true)
.context("error deleting torrent with files")?;
Ok(Default::default())
}