summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorsaperduper <[email protected]>2013-03-25 18:49:11 +0200
committersaperduper <[email protected]>2013-03-25 18:49:11 +0200
commit30123fe630da0c9882056de91460b2dd5912ad47 (patch)
tree1be6d630310cc2f57096141ed210b5dff12d0bbd /include
parent45b9c6fbcb1a83fdc2b335b8df89066146e5f8d6 (diff)
Handle future pubDate
Posts with pubDate in the future always appear at the top, which is ruining the whole "newest at top" idea. One way to handle this is to use time() instead. This is what google reader does and seems reasonable.
Diffstat (limited to 'include')
-rw-r--r--include/rssfuncs.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/rssfuncs.php b/include/rssfuncs.php
index 11aa0e4ba..130f9142c 100644
--- a/include/rssfuncs.php
+++ b/include/rssfuncs.php
@@ -435,7 +435,7 @@
$entry_timestamp = strtotime($item->get_date());
- if ($entry_timestamp == -1 || !$entry_timestamp) {
+ if ($entry_timestamp == -1 || !$entry_timestamp || $entry_timestamp > time()) {
$entry_timestamp = time();
$no_orig_date = 'true';
} else {