- Affected version
- 2.2.8 Patch 1
If you delete a thread, and then move it from a forum which counts posts to a forum which does not count posts; users of that thread get their post count updated twice.
This also applies to moving a deleted thread and then undeleting it, at which point the post-count is increased twice over what it should.
The problem is the very first part of
There is no check for the thread's current visibility.
This also applies to moving a deleted thread and then undeleting it, at which point the post-count is increased twice over what it should.
The problem is the very first part of
Thread::threadMoved
;
PHP:
protected function threadMoved(Forum $from, Forum $to)
{
if (!$this->isStateChanged('discussion_state', 'visible'))
{
$newCounts = $to->count_messages;
$oldCounts = $from->count_messages;
if ($newCounts != $oldCounts)
{
$this->adjustUserMessageCountIfNeeded($newCounts ? 1 : -1, true);
}
}
There is no check for the thread's current visibility.