We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8789634 commit 449e44cCopy full SHA for 449e44c
oma-fetch/src/download.rs
@@ -240,14 +240,17 @@ impl<'a> SingleDownloader<'a> {
240
trace!("{} download url is: {}", file.display(), source.url);
241
let mut dest = None;
242
let mut validator = None;
243
+ let is_symlink = file.is_symlink();
244
- if file.is_symlink() {
245
+ debug!("file {} is symlink = {}", file.display(), is_symlink);
246
+
247
+ if is_symlink {
248
tokio::fs::remove_file(&file).await.context(RemoveSnafu)?;
249
}
250
251
// 如果要下载的文件已经存在,则验证 Checksum 是否正确,若正确则添加总进度条的进度,并返回
252
// 如果不存在,则继续往下走
- if file_exist && !file.is_symlink() {
253
+ if file_exist && !is_symlink {
254
trace!(
255
"File {} already exists, verifying checksum ...",
256
self.entry.filename
0 commit comments