From 6b8a7db8e582f0975a7c913bf4bd7d152f1d81e3 Mon Sep 17 00:00:00 2001 From: Matt Beckett Date: Fri, 29 Jun 2012 00:50:32 -0600 Subject: fixes plugin hook for friend collections notifications --- mod/notifications/start.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'mod/notifications') diff --git a/mod/notifications/start.php b/mod/notifications/start.php index d5d418f0f..b76b0aa1e 100644 --- a/mod/notifications/start.php +++ b/mod/notifications/start.php @@ -25,7 +25,7 @@ function notifications_plugin_init() { // update notifications when new friend or access collection membership elgg_register_event_handler('create', 'friend', 'notifications_update_friend_notify'); - elgg_register_plugin_hook_handler('access:collections:add-user', 'collection', 'notifications_update_collection_notify'); + elgg_register_plugin_hook_handler('access:collections:add_user', 'collection', 'notifications_update_collection_notify'); $actions_base = elgg_get_plugins_path() . 'notifications/actions'; elgg_register_action("notificationsettings/save", "$actions_base/save.php"); @@ -194,7 +194,7 @@ function notifications_update_collection_notify($event, $object_type, $returnval } if (in_array($collection_id, $collections_preferences)) { // notifications are on for this collection so we add/remove - if ($event == 'access:collections:add-user') { + if ($event == 'access:collections:add_user') { add_entity_relationship($user->guid, "notify$method", $member_guid); } elseif ($event == 'access:collections:remove_user') { // removing someone from an access collection is not a guarantee -- cgit v1.2.3