Fix crashes when trying to view categories (fixes: #408)

This commit is contained in:
Daniel Martí 2013-11-10 18:53:23 +01:00
parent 080bab482d
commit 9b5c2656ee

View File

@ -636,9 +636,11 @@ public class DB {
while (!c.isAfterLast()) { while (!c.isAfterLast()) {
CommaSeparatedList categories = CommaSeparatedList CommaSeparatedList categories = CommaSeparatedList
.make(c.getString(0)); .make(c.getString(0));
for (String category : categories) { if (categories != null) {
if (!result.contains(category)) { for (String category : categories) {
result.add(category); if (!result.contains(category)) {
result.add(category);
}
} }
} }
c.moveToNext(); c.moveToNext();