Fix mis-encoding in Windows
This commit is contained in:
@@ -84,6 +84,15 @@ public final class StrUtils {
|
||||
return false;
|
||||
}
|
||||
|
||||
public static boolean startsWithOne(Collection<String> a, String match) {
|
||||
if (a == null)
|
||||
return false;
|
||||
for (String b : a)
|
||||
if (startsWith(match, b))
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
public static boolean equalsOne(String base, String... a) {
|
||||
for (String s : a)
|
||||
if (base.equals(s))
|
||||
|
||||
@@ -48,7 +48,7 @@ public class Localization {
|
||||
|
||||
this.lang = new HashMap<>();
|
||||
try {
|
||||
String[] strings = IOUtils.readFully(is).toString().split("\n");
|
||||
String[] strings = IOUtils.readFully(is).toString("UTF-8").split("\n");
|
||||
for (String s : strings)
|
||||
if (!s.isEmpty() && s.charAt(0) != 35) {
|
||||
int i = s.indexOf("=");
|
||||
|
||||
Reference in New Issue
Block a user