diff options
author | ByteHamster <ByteHamster@users.noreply.github.com> | 2023-05-05 17:19:06 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-05 17:19:06 +0200 |
commit | e2bbc3ef17687cfaa4c6a02507ed1cfd77665d37 (patch) | |
tree | ba3f6644128e1c974f28eee231d159b523bf404e | |
parent | 5a74279ce84abe1d6fd1b717863955ddc9873928 (diff) | |
download | AntennaPod-e2bbc3ef17687cfaa4c6a02507ed1cfd77665d37.zip |
Work around Android telling us zero-date when no date is present (#6450)
-rw-r--r-- | core/src/main/java/de/danoeh/antennapod/core/feed/LocalFeedUpdater.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/src/main/java/de/danoeh/antennapod/core/feed/LocalFeedUpdater.java b/core/src/main/java/de/danoeh/antennapod/core/feed/LocalFeedUpdater.java index d2a5b70fe..d4d948b2a 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/feed/LocalFeedUpdater.java +++ b/core/src/main/java/de/danoeh/antennapod/core/feed/LocalFeedUpdater.java @@ -204,7 +204,7 @@ public class LocalFeedUpdater { mediaMetadataRetriever.setDataSource(context, file.getUri()); String dateStr = mediaMetadataRetriever.extractMetadata(MediaMetadataRetriever.METADATA_KEY_DATE); - if (!TextUtils.isEmpty(dateStr)) { + if (!TextUtils.isEmpty(dateStr) && !"19040101T000000.000Z".equals(dateStr)) { try { SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyyMMdd'T'HHmmss", Locale.getDefault()); item.setPubDate(simpleDateFormat.parse(dateStr)); |