(&self)
| 375 | } |
| 376 | |
| 377 | pub fn remove_download_file(&self) { |
| 378 | let file_num = self.file_num as usize; |
| 379 | if file_num < self.files.len() { |
| 380 | let entry = &self.files[file_num]; |
| 381 | let path = self.join(&entry.name); |
| 382 | let download_path = format!("{}.download", get_string(&path)); |
| 383 | std::fs::remove_file(download_path).ok(); |
| 384 | } |
| 385 | } |
| 386 | |
| 387 | pub async fn write(&mut self, block: FileTransferBlock) -> ResultType<()> { |
| 388 | if block.id != self.id { |
nothing calls this directly
no test coverage detected