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 f3f7a89 commit 136b6dbCopy full SHA for 136b6db
javascript/extractor/src/com/semmle/js/extractor/AutoBuild.java
@@ -452,8 +452,13 @@ public int run() throws IOException {
452
} else {
453
warn("No JavaScript or TypeScript code found.");
454
}
455
- // ensuring that the finalize steps detects that no code was seen
456
- FileUtil8.recursiveDelete(Paths.get(EnvironmentVariables.getWipDatabase() + "/src"));
+ // ensuring that the finalize steps detects that no code was seen.
+ Path srcFolder = Paths.get(EnvironmentVariables.getWipDatabase() + "/src");
457
+ // check that the srcFolder is empty
458
+ if (Files.list(srcFolder).count() == 0) {
459
+ // Non-recursive delete because "src/" should be empty.
460
+ FileUtil8.delete(srcFolder);
461
+ }
462
return 0;
463
464
0 commit comments