[FIX] Удаление если прошлая загрузка сорвалась.

This commit is contained in:
Zaxar163 2019-09-15 19:41:24 +02:00
parent d210666df2
commit c17e59c4d1
No known key found for this signature in database
GPG key ID: 1FE4F2E1F053831B

View file

@ -57,6 +57,7 @@ public static void update(LauncherRequestEvent result) throws IOException {
}*/
try {
ListDownloader downloader = new ListDownloader();
Files.deleteIfExists(C_BINARY_PATH);
downloader.downloadOne(result.url, C_BINARY_PATH);
try (InputStream in = IOHelper.newInput(C_BINARY_PATH)) {
IOHelper.transfer(in, BINARY_PATH);