diff options
author | Cash Costello <cash.costello@gmail.com> | 2013-01-19 09:50:55 -0500 |
---|---|---|
committer | Cash Costello <cash.costello@gmail.com> | 2013-01-19 09:50:55 -0500 |
commit | 75d88938cb835183e10e9971ac383daa652367af (patch) | |
tree | 355b3f8717a2c705a0b1380b1b18358e79ef0253 /mod/notifications | |
parent | 3cfc0d3c2b5b4aaaa94179060370e1fe34668464 (diff) | |
download | elgg-75d88938cb835183e10e9971ac383daa652367af.tar.gz elgg-75d88938cb835183e10e9971ac383daa652367af.tar.bz2 |
Fixes #4983 added default paramter to get_input() to avoid warning
Diffstat (limited to 'mod/notifications')
-rw-r--r-- | mod/notifications/actions/groupsave.php | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/mod/notifications/actions/groupsave.php b/mod/notifications/actions/groupsave.php index 7838f7e63..2dd2a6db3 100644 --- a/mod/notifications/actions/groupsave.php +++ b/mod/notifications/actions/groupsave.php @@ -30,14 +30,11 @@ if ($groupmemberships = elgg_get_entities_from_relationship($options)) { } } -// Load important global vars -global $NOTIFICATION_HANDLERS; -foreach($NOTIFICATION_HANDLERS as $method => $foo) { - $subscriptions[$method] = get_input($method.'subscriptions'); - $personal[$method] = get_input($method.'personal'); - $collections[$method] = get_input($method.'collections'); - if (!empty($groups)) { - foreach($groups as $group) { +if (!empty($groups)) { + global $NOTIFICATION_HANDLERS; + foreach ($NOTIFICATION_HANDLERS as $method => $foo) { + $subscriptions[$method] = get_input($method.'subscriptions', array()); + foreach ($groups as $group) { if (in_array($group, $subscriptions[$method])) { add_entity_relationship($user->guid, 'notify'.$method, $group); } else { |