Skip to content

Commit

Permalink
CB-6026 use nio api for deletion (#3125)
Browse files Browse the repository at this point in the history
Co-authored-by: Evgenia <139753579+EvgeniaBzzz@users.noreply.github.com>
  • Loading branch information
alexander-skoblikov and EvgeniaBzzz authored Dec 11, 2024
1 parent 4b2e1a9 commit c2523a6
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,7 @@ public void deleteResource(@NotNull String projectId, @NotNull String resourcePa
log.warn("Failed to remove resources properties", e);
}
try {
if (targetPath.toFile().isDirectory()) {
if (Files.isDirectory(targetPath)) {
IOUtils.deleteDirectory(targetPath);
} else {
Files.delete(targetPath);
Expand Down

0 comments on commit c2523a6

Please sign in to comment.