Fixed RSS feed does not set right "pubDate"

TickTackk

Well-known member
Affected version
2.1.10
In src\XF\Pub\Controller\Forum.php it accepts order field for sorting
PHP:
        $order = $this->filter('order', 'str');
        switch ($order)
        {
            case 'post_date':
                break;

            default:
                $order = 'last_post_date';
                break;
        }
        $threadList->order($order, 'DESC');

In src\XF\Pub\View\Forum\Rss.php
PHP:
                ->setDateCreated($thread->post_date)
                ->setDateModified($thread->last_post_date);
It sets both thread's first and last post timestamp when it should only call setDateModified IF the order set in the URL is not post_date otherwise no matter what the order is set it's always the last_post_date value that is considered as "pubDate"
 
Hello is this bug fixed?
In src\XF\Pub\Controller\Forum.php it accepts order field for sorting
PHP:
        $order = $this->filter('order', 'str');
        switch ($order)
        {
            case 'post_date':
                break;

            default:
                $order = 'last_post_date';
                break;
        }
        $threadList->order($order, 'DESC');

In src\XF\Pub\View\Forum\Rss.php
PHP:
                ->setDateCreated($thread->post_date)
                ->setDateModified($thread->last_post_date);
It sets both thread's first and last post timestamp when it should only call setDateModified IF the order set in the URL is not post_date otherwise no matter what the order is set it's always the last_post_date value that is considered as "pubDate"
 
Thank you for reporting this issue, it has now been resolved. We are aiming to include any changes that have been made in a future XF release (2.2.0 Beta 6).

Change log:
Set publish dates of forum RSS feed entries based on order
There may be a delay before changes are rolled out to the XenForo Community.
 
Back
Top Bottom