mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-21 13:54:02 -07:00
Minor improvements (#1532)
* Minor improvements * Update clean_dlstat.php * Updated * Update usercp_viewprofile.tpl * Update CHANGELOG.md
This commit is contained in:
parent
ccf6ba3099
commit
d2a1a7f5f9
5 changed files with 4 additions and 18 deletions
|
@ -35,19 +35,6 @@ if ($delete_dlstat_sql = implode(') OR (', $delete_dlstat_sql)) {
|
|||
DB()->query("DELETE QUICK FROM " . BB_BT_DLSTATUS . " WHERE ($delete_dlstat_sql)");
|
||||
}
|
||||
|
||||
// Save the last 50 votes for topics
|
||||
DB()->query('
|
||||
DELETE t1
|
||||
FROM ' . BB_THX . ' t1
|
||||
JOIN (
|
||||
SELECT topic_id, MAX(time) as max_time
|
||||
FROM ' . BB_THX . '
|
||||
GROUP BY topic_id
|
||||
HAVING COUNT(*) > 50
|
||||
) t2
|
||||
ON t1.topic_id = t2.topic_id AND t1.time = t2.max_time;
|
||||
');
|
||||
|
||||
// Delete orphans
|
||||
DB()->query("
|
||||
DELETE QUICK dl
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue