Skip to content

Commit e93ae84

Browse files
committed
fix: copy files dir in importTrace only if output folder different from input one
it seems that if they are the same, the copy leaves the files empty in the target folder: i assume behaviour of copy dir no recursive
1 parent a7f2b7b commit e93ae84

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/ct/trace/storage_and_import.nim

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,8 @@ proc importTrace*(
172172
break # for now assume the first detected lang is ok
173173

174174
if dirExists(traceFolder / "files"):
175-
copyDir(traceFolder / "files", outputFolder / "files")
175+
if traceFolder != outputFolder:
176+
copyDir(traceFolder / "files", outputFolder / "files")
176177
elif selfContained and downloadUrl == "":
177178
# for now assuming if no `files/` dir already,
178179
# it happens on the original machine

0 commit comments

Comments
 (0)