From f9f8a78753bdecbd5999f846f731c304e6b67cd3 Mon Sep 17 00:00:00 2001 From: Shane Freeder Date: Sat, 23 Jul 2022 05:52:57 +0100 Subject: [PATCH] Fix plugin update IO logic when replacing jars --- patches/api/Update-Folder-Uses-Plugin-Name.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/patches/api/Update-Folder-Uses-Plugin-Name.patch b/patches/api/Update-Folder-Uses-Plugin-Name.patch index a633c4c6a0..3f59b529ec 100644 --- a/patches/api/Update-Folder-Uses-Plugin-Name.patch +++ b/patches/api/Update-Folder-Uses-Plugin-Name.patch @@ -49,7 +49,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 + } + if (!pluginName.equals(updatePluginName)) continue; + try { -+ java.nio.file.Files.copy(updateFile.toPath(), file.toPath()); ++ java.nio.file.Files.copy(updateFile.toPath(), file.toPath(), java.nio.file.StandardCopyOption.REPLACE_EXISTING); + } catch (java.io.IOException exception) { + server.getLogger().log(Level.SEVERE, "Could not copy '" + updateFile.getPath() + "' to '" + file.getPath() + "' in update plugin process", exception); + continue;