Fix ArrayIndexOutOfBoundsException
See Play store crash report No idea why this happens...
This commit is contained in:
parent
d91e9f4d6f
commit
6bf4d28c34
|
@ -335,7 +335,7 @@ public class AllEpisodesFragment extends Fragment {
|
|||
|
||||
@Override
|
||||
public int getCount() {
|
||||
if (itemsLoaded) {
|
||||
if (episodes != null) {
|
||||
return episodes.size();
|
||||
}
|
||||
return 0;
|
||||
|
@ -343,7 +343,7 @@ public class AllEpisodesFragment extends Fragment {
|
|||
|
||||
@Override
|
||||
public FeedItem getItem(int position) {
|
||||
if (itemsLoaded) {
|
||||
if (episodes != null && position < episodes.size()) {
|
||||
return episodes.get(position);
|
||||
}
|
||||
return null;
|
||||
|
|
Loading…
Reference in New Issue