Forums

Unfortunately no one can be told what FluxBB is - you have to see it for yourself.

You are not logged in.

#1 2012-02-22 06:27:54

Newman
Member
Registered: 2011-11-05
Posts: 350

Performance Hack [Large Boards]

POST.php find:

$db->query('UPDATE '.$db->prefix.'topics SET num_replies='.$num_replies.',

replace:


$db->query('UPDATE '.$db->prefix.'topics SET num_replies=num_replies+1,

delete :


$result = $db->query('SELECT COUNT(id) FROM '.$db->prefix.'posts WHERE topic_id='.$tid) or error('Unable to fetch post count for topic', __FILE__, __LINE__, $db->error());
			$num_replies = $db->result($result, 0) - 1;

There is no need for that query to run, will save performance in larger boards only.

Enjoy!

Offline

#2 2012-02-22 11:38:27

Reines
Administrator
From: Scotland
Registered: 2008-05-11
Posts: 3,197
Website

Re: Performance Hack [Large Boards]

Can you please make a ticket for things like this? Cheers

Offline

Board footer

Powered by FluxBB