mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-31 01:35:36 +02:00
#10152 fixed error 500 message notification groups
This commit is contained in:
parent
bc5e1c7541
commit
e16ef7063a
@ -143,12 +143,20 @@ function users_get_groups_for_select(
|
|||||||
);
|
);
|
||||||
|
|
||||||
if ($id_groups !== null && empty($id_groups) === false) {
|
if ($id_groups !== null && empty($id_groups) === false) {
|
||||||
$children = groups_get_children($id_groups);
|
$children = [];
|
||||||
foreach ($children as $child) {
|
foreach ($id_groups as $key => $id_group) {
|
||||||
unset($user_groups[$child['id_grupo']]);
|
$children[] = groups_get_children($id_group);
|
||||||
}
|
}
|
||||||
|
|
||||||
unset($user_groups[$id_groups]);
|
if (empty($children) === false) {
|
||||||
|
foreach ($children as $child) {
|
||||||
|
unset($user_groups[$child['id_grupo']]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach ($id_groups as $key => $id_group) {
|
||||||
|
unset($user_groups[$id_group]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (empty($user_groups)) {
|
if (empty($user_groups)) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user