1
0
Fork 0
mirror of https://github.com/vanitasvitae/Smack.git synced 2025-09-10 09:39:39 +02:00

Support building with Java8

This commit is contained in:
Florian Schmaus 2014-07-25 09:26:26 +02:00
parent f05e744011
commit 3634587933
2 changed files with 10 additions and 1 deletions

View file

@ -796,7 +796,10 @@ public class PacketParserUtilsTest {
for (int i = 0; i < availableLocales.length; i++) {
if (availableLocales[i] != Locale.getDefault()) {
otherLanguage = availableLocales[i].getLanguage().toLowerCase(Locale.US);
break;
// Check for empty strings as Java8 returns those here for certain Locales
if (otherLanguage.length() > 0) {
break;
}
}
}
return otherLanguage;