Fixed empty config Strings being overridden by defaults

This commit is contained in:
Rsl1122 2019-01-17 12:40:06 +02:00
parent b1bcb962cb
commit f9c55850de

View File

@ -93,7 +93,7 @@ public interface ConfigValueParser<T> {
boolean surroundedByQuotes = value.startsWith("'") || value.endsWith("'");
boolean surroundedByDoubleQuotes = value.startsWith("\"") || value.endsWith("\"");
boolean containsSpace = value.contains(" ");
boolean containsSpace = value.isEmpty() || value.contains(" ");
boolean startsWithSpecialSymbol = value.startsWith("-") || value.startsWith("#") || value.startsWith("&");
if (surroundedByDoubleQuotes || containsSpace || startsWithSpecialSymbol) {