refactor: GIF 单独归类、跨文件系统复制回退与异常处理优化

This commit is contained in:
2025-03-12 21:01:04 +08:00
parent 9ed579d04e
commit 0ebd84d3fe
6 changed files with 83 additions and 14 deletions
+6 -1
View File
@@ -34,7 +34,12 @@ func doReadFileMimeInfo() {
bar.SetNoticeColor(goPrint.FontColor.Red)
for _, currentPath := range vars.GlobalFilePathList {
// mime
vars.GlobalFilePath2MimeInfoMap[currentPath] = util.ReadFileMimeInfo(currentPath).String()
mt := util.ReadFileMimeInfo(currentPath)
if mt != nil {
vars.GlobalFilePath2MimeInfoMap[currentPath] = mt.String()
} else {
vars.GlobalFilePath2MimeInfoMap[currentPath] = ""
}
count = count + 1
bar.PrintBar(util.CalcPercentage(count, total))
}