Adds various fixes to make the two java versions work as expected
Makes it possible to load a controller without generating a GUI, for better testing Makes sure not to try and parse empty profile lines Saves controller settings in a more readable and appendable format Adds code for using the correct java version for the occasion Adds a new function for writing to files
This commit is contained in:
@ -8,7 +8,7 @@ import net.knarcraft.minecraftserverlauncher.utility.CommonFunctions;
|
||||
|
||||
import javax.naming.ConfigurationException;
|
||||
import javax.swing.*;
|
||||
import java.io.*;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
|
||||
/**
|
||||
@ -230,7 +230,9 @@ public class Profile {
|
||||
*/
|
||||
public static Profile fromString(String profileString) throws ConfigurationException {
|
||||
Profile profile;
|
||||
if (profileString.contains("?")) {
|
||||
if (profileString.equals("")) {
|
||||
return null;
|
||||
} else if (profileString.contains("?")) {
|
||||
String[] data = profileString.split("\\?");
|
||||
String[] profileData = data[0].split(";", -1);
|
||||
profile = parseProfile(profileData);
|
||||
|
Reference in New Issue
Block a user