diff --git a/xwords4/android/XWords4/src/org/eehouse/android/xw4/GamesListDelegate.java b/xwords4/android/XWords4/src/org/eehouse/android/xw4/GamesListDelegate.java index 490b4c9c5..98c809d78 100644 --- a/xwords4/android/XWords4/src/org/eehouse/android/xw4/GamesListDelegate.java +++ b/xwords4/android/XWords4/src/org/eehouse/android/xw4/GamesListDelegate.java @@ -205,9 +205,12 @@ public class GamesListDelegate extends ListDelegateBase // If the game's not visible, update the parent group in case // the game's changed in a way that makes it draw differently long parent = DBUtils.getGroupForGame( m_activity, rowID ); - GameListGroup group = getGroupWithID( parent ).iterator().next(); - GameGroupInfo ggi = DBUtils.getGroups( m_activity ).get( parent ); - updateGroupPct( group, ggi ); + Iterator iter = getGroupWithID( parent ).iterator(); + if ( iter.hasNext() ) { + GameListGroup group = iter.next(); + GameGroupInfo ggi = DBUtils.getGroups( m_activity ).get( parent ); + updateGroupPct( group, ggi ); + } } return item; } @@ -419,7 +422,6 @@ public class GamesListDelegate extends ListDelegateBase Set groupIDs = new HashSet(); groupIDs.add( groupID ); Set result = getGroupsWithIDs( groupIDs ); - Assert.assertTrue( 1 == groupIDs.size() ); return result; }