Active
Project:
Mailman Groups
Version:
6.x-2.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
10 Jan 2011 at 12:09 UTC
Updated:
21 Feb 2011 at 02:39 UTC
So the function
function _mailman_groups_getlists() {
$access = array();
// Values used to check against the "hide" field.
$hide_by_member = is_callable('og_is_group_member') ? 1 : 0;
$hide_by_domain = is_callable('og_abt_domain_group_in_domain') ? 2 : 0;
// Process group->list relationships...
$result = db_query('SELECT * FROM {mailman_groups}');
while ($link = db_fetch_array($result)) {
// Extract ($gid, $lid, $hide)
extract($link);
if ($access[$lid]) {
continue;
}
elseif (!$hide) {
$access[$lid] = TRUE;
}
elseif ($hide == $hide_by_member && og_is_group_member($gid)) {
$access[$lid] = TRUE;
}
elseif ($hide == $hide_by_domain && og_abt_domain_group_in_domain($gid)) {
$access[$lid] = TRUE;
}
}
return $access;
}
returns an array of lists and whether the user has access or not to each list in the array. But, if there are lists that are not handled by mailman_groups, they will also be hidden because they will not be in the mailman_groups table. Only lists that have been linked to groups are in the mailman_group table, but we still want non-group lists to show up in the form for users to subscribe / unsubscribe.
Comments
Comment #1
mahendrad_us commentedI am also having same issue. User Mailman Register shows all the lists regardless of the groups that they have linked. Have you found a fix? I searched everywhere but couldn't find.
Regards