Fixed markForumTreeReadByVisitor read triggers N+1 query behaviour

Xon

Well-known member
Affected version
2.2.2
Despite fetching the full node list, XF\Repository\Forum::markForumTreeReadByVisitor triggers two selects per forum being marked-as-read.

I'm fairly sure this could also be reduced to an insert/select filtering by lft/rgt for bulk marking as read without needing an insert for every row
 
Last edited:
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.3).

Change log:
Optimize marking multiple forums read at once.
There may be a delay before changes are rolled out to the XenForo Community.
 
Back
Top Bottom