Fix NPE and hide progress bar without media
This commit is contained in:
parent
e98041c7ba
commit
69303a5915
|
@ -122,7 +122,11 @@ public class NewEpisodesListAdapter extends BaseAdapter {
|
|||
holder.downloadProgress.setProgress(itemAccess.getItemDownloadProgressPercent(item));
|
||||
}
|
||||
}
|
||||
} else {
|
||||
holder.downloadProgress.setVisibility(View.GONE);
|
||||
holder.txtvDuration.setVisibility(View.GONE);
|
||||
}
|
||||
|
||||
if (itemAccess.isInQueue(item)) {
|
||||
holder.queueStatus.setVisibility(View.VISIBLE);
|
||||
} else {
|
||||
|
|
|
@ -318,7 +318,7 @@ public class FeedItem extends FeedComponent implements ShownotesProvider, Flattr
|
|||
|
||||
@Override
|
||||
public Uri getImageUri() {
|
||||
if(media.hasEmbeddedPicture()) {
|
||||
if(media != null && media.hasEmbeddedPicture()) {
|
||||
return media.getImageUri();
|
||||
} else if (hasItemImageDownloaded()) {
|
||||
return image.getImageUri();
|
||||
|
|
Loading…
Reference in New Issue