Skip to content

Commit

Permalink
don't replace the old file if failed
Browse files Browse the repository at this point in the history
  • Loading branch information
hafarooki committed Aug 14, 2019
1 parent c81f607 commit d4f15b2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/java/net/starlegacy/explosionregen/WorldData.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
import org.bukkit.block.data.BlockData;

import java.io.*;
import java.nio.file.CopyOption;
import java.nio.file.Files;
import java.nio.file.StandardCopyOption;
import java.util.*;
Expand Down Expand Up @@ -133,9 +132,10 @@ public void save(World world) {
output.write(tileData);
}
}
} catch (IOException e) {
} catch (Exception e) {
e.printStackTrace();
tmpFile.delete();
return;
}

try {
Expand Down

0 comments on commit d4f15b2

Please sign in to comment.