[ticket/12371] Fix SQL query

PHPBB3-12371
This commit is contained in:
Joas Schilling 2014-04-11 14:40:03 +02:00
parent 5512e62c3c
commit 8375c3f789

View file

@ -1051,7 +1051,7 @@ class acp_users
$sql = 'SELECT COUNT(post_id) as posts_in_queue $sql = 'SELECT COUNT(post_id) as posts_in_queue
FROM ' . POSTS_TABLE . ' FROM ' . POSTS_TABLE . '
WHERE poster_id = ' . $user_id . ' WHERE poster_id = ' . $user_id . '
AND post_visibility = ' . $db->sql_in_set('post_visibility', array(ITEM_UNAPPROVED, ITEM_REAPPROVE)); AND ' . $db->sql_in_set('post_visibility', array(ITEM_UNAPPROVED, ITEM_REAPPROVE));
$result = $db->sql_query($sql); $result = $db->sql_query($sql);
$user_row['posts_in_queue'] = (int) $db->sql_fetchfield('posts_in_queue'); $user_row['posts_in_queue'] = (int) $db->sql_fetchfield('posts_in_queue');
$db->sql_freeresult($result); $db->sql_freeresult($result);