diff options
author | Decebal Suiu <decebal.suiu@gmail.com> | 2019-04-13 23:25:04 +0300 |
---|---|---|
committer | Decebal Suiu <decebal.suiu@gmail.com> | 2019-04-13 23:25:04 +0300 |
commit | dd45a1e6dcfdcc39b3fe182417d48a2e801f7d28 (patch) | |
tree | 9c4ae713d7eccdbdc7e12d32b1b8ee5fe667cc04 | |
parent | 6b92361aad38d2628111eada57c56f4af625b374 (diff) | |
download | pf4j-dd45a1e6dcfdcc39b3fe182417d48a2e801f7d28.tar.gz pf4j-dd45a1e6dcfdcc39b3fe182417d48a2e801f7d28.zip |
Fix issue (the plugin directory will be deleted anyway in unzip extract method)
-rw-r--r-- | pf4j/src/main/java/org/pf4j/util/FileUtils.java | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/pf4j/src/main/java/org/pf4j/util/FileUtils.java b/pf4j/src/main/java/org/pf4j/util/FileUtils.java index 7bd7abe..0cb8784 100644 --- a/pf4j/src/main/java/org/pf4j/util/FileUtils.java +++ b/pf4j/src/main/java/org/pf4j/util/FileUtils.java @@ -176,14 +176,6 @@ public class FileUtils { Path pluginDirectory = filePath.resolveSibling(directoryName); if (!Files.exists(pluginDirectory) || pluginZipDate.compareTo(Files.getLastModifiedTime(pluginDirectory)) > 0) { - // do not overwrite an old version, remove it - if (Files.exists(pluginDirectory)) { - FileUtils.delete(pluginDirectory); - } - - // create root for plugin - Files.createDirectories(pluginDirectory); - // expand '.zip' file Unzip unzip = new Unzip(); unzip.setSource(filePath.toFile()); |