1
0

fix fallthrough setting of localized metadata entries

Java's Map.get() returns null if there is no match, so this was always
setting each entry to whatever value was in the highest priority
locale, whether it had contents or what null.  Now, this will fall
through the priority list of locales until it finds actually contents.
Este cometimento está contido em:
Hans-Christoph Steiner 2017-04-17 15:42:09 +02:00
ascendente 4bb7050725
cometimento 670e6be39a

Ver ficheiro

@ -433,7 +433,10 @@ public class App extends ValueObject implements Comparable<App>, Parcelable {
try {
for (String locale : locales) {
if (localized.containsKey(locale)) {
return (String) localized.get(locale).get(key);
String value = (String) localized.get(locale).get(key);
if (value != null) {
return value;
}
}
}
} catch (ClassCastException e) {