diff options
author | ByteHamster <ByteHamster@users.noreply.github.com> | 2023-09-27 21:54:50 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-27 21:54:50 +0200 |
commit | 7229cb40e946a895cdd804cb344aae440dbbe816 (patch) | |
tree | 480c30bb7efdff67dc2fca3761a52dd0990553a5 /core/src | |
parent | 574ec1434c885429e0d9b4061dff765eb7284701 (diff) | |
download | AntennaPod-7229cb40e946a895cdd804cb344aae440dbbe816.zip |
Don't update redirect url if it is the same as the original (#6661)
Diffstat (limited to 'core/src')
-rw-r--r-- | core/src/main/java/de/danoeh/antennapod/core/service/FeedUpdateWorker.java | 3 | ||||
-rw-r--r-- | core/src/main/java/de/danoeh/antennapod/core/storage/DBTasks.java | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/core/src/main/java/de/danoeh/antennapod/core/service/FeedUpdateWorker.java b/core/src/main/java/de/danoeh/antennapod/core/service/FeedUpdateWorker.java index 59d9df8f5..2f763e78e 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/service/FeedUpdateWorker.java +++ b/core/src/main/java/de/danoeh/antennapod/core/service/FeedUpdateWorker.java @@ -176,7 +176,8 @@ public class FeedUpdateWorker extends Worker { newEpisodesNotification.showIfNeeded(getApplicationContext(), feedSyncTask.getSavedFeed()); if (downloader.permanentRedirectUrl != null) { DBWriter.updateFeedDownloadURL(request.getSource(), downloader.permanentRedirectUrl); - } else if (feedSyncTask.getRedirectUrl() != null) { + } else if (feedSyncTask.getRedirectUrl() != null + && !feedSyncTask.getRedirectUrl().equals(request.getSource())) { DBWriter.updateFeedDownloadURL(request.getSource(), feedSyncTask.getRedirectUrl()); } } diff --git a/core/src/main/java/de/danoeh/antennapod/core/storage/DBTasks.java b/core/src/main/java/de/danoeh/antennapod/core/storage/DBTasks.java index d42f14591..d6a4fa1cb 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/storage/DBTasks.java +++ b/core/src/main/java/de/danoeh/antennapod/core/storage/DBTasks.java @@ -281,7 +281,7 @@ public final class DBTasks { if (oldItem != null) { oldItem.updateFromOther(item); } else { - // item is new + Log.d(TAG, "Found new item: " + item.getTitle()); item.setFeed(savedFeed); if (idx >= savedFeed.getItems().size()) { |