Bug \XF\Entity\Thread::getCoverImage does not consider all thumbnails as candidates

There is a bug in this version
K

Kirby

Guest
PHP:

Code:
$attachments = $attachments->filter(function(Attachment $attachment) use ($canViewAttachments)
{
    if ($attachment->type_grouping != 'image')
    {
        return false;
    }

    return $canViewAttachments || $attachment->hasThumbnail();
});

This code ignores attachments that have thumbnails but are not grouped as images.

Changing this to
PHP:

Code:
$attachments = $attachments->filter(function(Attachment $attachment) use ($canViewAttachments)
{
    return $canViewAttachments ||...

Read more

Continue reading...