diff options
Diffstat (limited to 'app/src/main')
-rw-r--r-- | app/src/main/java/de/danoeh/antennapod/adapter/DownloadLogAdapter.java | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/DownloadLogAdapter.java b/app/src/main/java/de/danoeh/antennapod/adapter/DownloadLogAdapter.java index f29cfdf2f..0eb15da8c 100644 --- a/app/src/main/java/de/danoeh/antennapod/adapter/DownloadLogAdapter.java +++ b/app/src/main/java/de/danoeh/antennapod/adapter/DownloadLogAdapter.java @@ -124,11 +124,15 @@ public class DownloadLogAdapter extends BaseAdapter { ButtonHolder holder = (ButtonHolder) v.getTag(); if(holder.typeId == Feed.FEEDFILETYPE_FEED) { Feed feed = DBReader.getFeed(context, holder.id); - feed.setLastUpdate(new Date(0)); // force refresh - try { - DBTasks.refreshFeed(context, feed); - } catch (DownloadRequestException e) { - e.printStackTrace(); + if (feed != null) { + feed.setLastUpdate(new Date(0)); // force refresh + try { + DBTasks.refreshFeed(context, feed); + } catch (DownloadRequestException e) { + e.printStackTrace(); + } + } else { + Log.wtf(TAG, "Could not find feed for feed id: " + holder.id); } } else if(holder.typeId == FeedMedia.FEEDFILETYPE_FEEDMEDIA) { FeedMedia media = DBReader.getFeedMedia(context, holder.id); |