Tries a new fix to remove the pesky FileNotFoundException caused by the server version container
Some checks failed
KnarCraft/Minecraft-Server-Launcher/pipeline/head There was a failure building this commit
Some checks failed
KnarCraft/Minecraft-Server-Launcher/pipeline/head There was a failure building this commit
This commit is contained in:
@ -92,6 +92,11 @@ public class ServerVersionContainer implements java.io.Serializable {
|
||||
PrintWriter file;
|
||||
try {
|
||||
if (!saveFile.exists()) {
|
||||
if (!saveFile.getParentFile().exists()) {
|
||||
if (!saveFile.getParentFile().mkdirs()) {
|
||||
throw new FileNotFoundException("Unable to create folder for version file");
|
||||
}
|
||||
}
|
||||
if (!saveFile.createNewFile()) {
|
||||
throw new FileNotFoundException("Unable to create version file");
|
||||
}
|
||||
|
Reference in New Issue
Block a user