aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--phpBB/docs/CHANGELOG.html1
-rw-r--r--phpBB/memberlist.php24
2 files changed, 21 insertions, 4 deletions
diff --git a/phpBB/docs/CHANGELOG.html b/phpBB/docs/CHANGELOG.html
index 8355dbf1e1..b78fa1f373 100644
--- a/phpBB/docs/CHANGELOG.html
+++ b/phpBB/docs/CHANGELOG.html
@@ -90,6 +90,7 @@
<li>[Fix] Regression bug from revision #8908 regarding log display in ACP</li>
<li>[Fix] Allow the UCP group management to work for groups with avatars. (Bug #37375)</li>
<li>[Fix] Fix header list build for replying oldest PM in PM history (Bug #37275)</li>
+ <li>[Fix] Do not display COPPA group in memberlist find member dialog if COPPA disabled (Bug #37175)</li>
</ul>
<a name="v302"></a><h3>1.ii. Changes since 3.0.2</h3>
diff --git a/phpBB/memberlist.php b/phpBB/memberlist.php
index c78acaf92d..ad2efe5229 100644
--- a/phpBB/memberlist.php
+++ b/phpBB/memberlist.php
@@ -1276,11 +1276,21 @@ switch ($mode)
$s_group_select = '<option value="0"' . ((!$group_selected) ? ' selected="selected"' : '') . '>&nbsp;</option>';
$group_ids = array();
+ /**
+ * @todo add this to a separate function (function is responsible for returning the groups the user is able to see based on the users group membership)
+ */
+
if ($auth->acl_gets('a_group', 'a_groupadd', 'a_groupdel'))
{
$sql = 'SELECT group_id, group_name, group_type
- FROM ' . GROUPS_TABLE . '
- ORDER BY group_name ASC';
+ FROM ' . GROUPS_TABLE;
+
+ if (!$config['coppa_enable'])
+ {
+ $sql .= " WHERE group_name <> 'REGISTERED_COPPA'";
+ }
+
+ $sql .= ' ORDER BY group_name ASC';
}
else
{
@@ -1292,8 +1302,14 @@ switch ($mode)
AND ug.user_id = ' . $user->data['user_id'] . '
AND ug.user_pending = 0
)
- WHERE (g.group_type <> ' . GROUP_HIDDEN . ' OR ug.user_id = ' . $user->data['user_id'] . ')
- ORDER BY g.group_name ASC';
+ WHERE (g.group_type <> ' . GROUP_HIDDEN . ' OR ug.user_id = ' . $user->data['user_id'] . ')';
+
+ if (!$config['coppa_enable'])
+ {
+ $sql .= " WHERE group_name <> 'REGISTERED_COPPA'";
+ }
+
+ $sql .= ' ORDER BY g.group_name ASC';
}
$result = $db->sql_query($sql);