Skip to content

Commit 389c05a

Browse files
committed
fix revisions used in RSS feeds. fixes dokuwiki#4357
A negative value needs to be passed to retrieve the current revision.
1 parent b67cd41 commit 389c05a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

inc/Feed/FeedMediaProcessor.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ public function isExisting()
139139
protected function loadRevisions()
140140
{
141141
$changelog = new MediaChangeLog($this->id);
142-
$revs = $changelog->getRevisions(0, 2); // FIXME check that this returns the current one correctly
142+
$revs = $changelog->getRevisions(-1, 2);
143143
if (!isset($this->data['rev'])) {
144144
// prefer an already set date, only set if missing
145145
// it should usally not happen that neither is available

inc/Feed/FeedPageProcessor.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ protected function getMetaData()
185185
protected function loadRevisions()
186186
{
187187
$changelog = new PageChangeLog($this->id);
188-
$revs = $changelog->getRevisions(0, 2); // FIXME check that this returns the current one correctly
188+
$revs = $changelog->getRevisions(-1, 2);
189189
if (!isset($this->data['rev'])) {
190190
// prefer an already set date, only set if missing
191191
// it should usally not happen that neither is available

0 commit comments

Comments
 (0)