diff options
author | Martin Fietz <Martin.Fietz@gmail.com> | 2016-01-27 13:27:16 +0100 |
---|---|---|
committer | Martin Fietz <Martin.Fietz@gmail.com> | 2016-01-27 13:27:16 +0100 |
commit | d675f74dcbf1875b4a8fbaee2503764496ff06ec (patch) | |
tree | d84afefdbbd6eae9e92e080ceced20412c80739f /app | |
parent | c1819864fe4e46945c42584a571cabc96c338644 (diff) | |
download | AntennaPod-d675f74dcbf1875b4a8fbaee2503764496ff06ec.zip |
Prevent NPE
Diffstat (limited to 'app')
-rw-r--r-- | app/src/main/java/de/danoeh/antennapod/fragment/ChaptersFragment.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/ChaptersFragment.java b/app/src/main/java/de/danoeh/antennapod/fragment/ChaptersFragment.java index ce1d753e8..96abdd835 100644 --- a/app/src/main/java/de/danoeh/antennapod/fragment/ChaptersFragment.java +++ b/app/src/main/java/de/danoeh/antennapod/fragment/ChaptersFragment.java @@ -68,7 +68,7 @@ public class ChaptersFragment extends ListFragment implements AudioplayerContent this.media = media; adapter.setMedia(media); adapter.notifyDataSetChanged(); - if(media.getChapters() == null) { + if(media == null || media.getChapters() == null || media.getChapters().size() == 0) { setEmptyText(getString(R.string.no_items_label)); } else { setEmptyText(null); |