aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/search.php
diff options
context:
space:
mode:
authorNathan Guse <nathaniel.guse@gmail.com>2013-07-22 12:20:17 -0700
committerNathan Guse <nathaniel.guse@gmail.com>2013-07-22 12:20:17 -0700
commit127ee62eddf07d705c9b243169db338ee4cbfaef (patch)
tree2930da727f871dc9f65e3716975661ff8935a759 /phpBB/search.php
parentb71038486e067daf0c608d73aabeb60a56e86840 (diff)
parenteffafa4b4d82e8f0debcda2e84e03117433e5a7d (diff)
downloadforums-127ee62eddf07d705c9b243169db338ee4cbfaef.tar
forums-127ee62eddf07d705c9b243169db338ee4cbfaef.tar.gz
forums-127ee62eddf07d705c9b243169db338ee4cbfaef.tar.bz2
forums-127ee62eddf07d705c9b243169db338ee4cbfaef.tar.xz
forums-127ee62eddf07d705c9b243169db338ee4cbfaef.zip
Merge pull request #1589 from marc1706/ticket/11717
[ticket/11717] Use topic_posts_approved instead of topic_replies
Diffstat (limited to 'phpBB/search.php')
-rw-r--r--phpBB/search.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/phpBB/search.php b/phpBB/search.php
index 2429c81dae..8bcbfc498b 100644
--- a/phpBB/search.php
+++ b/phpBB/search.php
@@ -366,7 +366,7 @@ if ($keywords || $author || $author_id || $search_id || $submit)
{
$sql = "SELECT p.post_id
FROM $sort_join" . POSTS_TABLE . ' p, ' . TOPICS_TABLE . " t
- WHERE t.topic_replies = 0
+ WHERE t.topic_posts_approved = 1
AND p.topic_id = t.topic_id
$last_post_time
AND $m_approve_posts_fid_sql
@@ -378,7 +378,7 @@ if ($keywords || $author || $author_id || $search_id || $submit)
{
$sql = 'SELECT DISTINCT ' . $sort_by_sql[$sort_key] . ", p.topic_id
FROM $sort_join" . POSTS_TABLE . ' p, ' . TOPICS_TABLE . " t
- WHERE t.topic_replies = 0
+ WHERE t.topic_posts_approved = 1
AND t.topic_moved_id = 0
AND p.topic_id = t.topic_id
$last_post_time