From fe8096753566f4beb708e9070d8789eebdd1e70b Mon Sep 17 00:00:00 2001 From: Tristan Darricau Date: Sat, 16 Aug 2014 21:06:10 +0200 Subject: [ticket/12990] Use the full services name for the notification's types PHPBB3-12990 --- phpBB/includes/ucp/ucp_notifications.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'phpBB/includes/ucp/ucp_notifications.php') diff --git a/phpBB/includes/ucp/ucp_notifications.php b/phpBB/includes/ucp/ucp_notifications.php index 0ed3084e9f..690a16c5f6 100644 --- a/phpBB/includes/ucp/ucp_notifications.php +++ b/phpBB/includes/ucp/ucp_notifications.php @@ -58,28 +58,28 @@ class ucp_notifications { foreach($notification_methods as $method => $method_data) { - if ($request->is_set_post($type . '_' . $method_data['id']) && (!isset($subscriptions[$type]) || !in_array($method_data['id'], $subscriptions[$type]))) + if ($request->is_set_post(str_replace('.', '_', $type . '_' . $method_data['id'])) && (!isset($subscriptions[$type]) || !in_array($method_data['id'], $subscriptions[$type]))) { $phpbb_notifications->add_subscription($type, 0, $method_data['id']); } - else if (!$request->is_set_post($type . '_' . $method_data['id']) && isset($subscriptions[$type]) && in_array($method_data['id'], $subscriptions[$type])) + else if (!$request->is_set_post(str_replace('.', '_', $type . '_' . $method_data['id'])) && isset($subscriptions[$type]) && in_array($method_data['id'], $subscriptions[$type])) { $phpbb_notifications->delete_subscription($type, 0, $method_data['id']); } } - if ($request->is_set_post($type . '_notification') && !isset($subscriptions[$type])) + if ($request->is_set_post(str_replace('.', '_', $type) . '_notification') && !isset($subscriptions[$type])) { $phpbb_notifications->add_subscription($type); } - else if (!$request->is_set_post($type . '_notification') && isset($subscriptions[$type])) + else if (!$request->is_set_post(str_replace('.', '_', $type) . '_notification') && isset($subscriptions[$type])) { $phpbb_notifications->delete_subscription($type); } } } - meta_refresh(3, $this->u_action); + //meta_refresh(3, $this->u_action); $message = $user->lang['PREFERENCES_UPDATED'] . '

' . sprintf($user->lang['RETURN_UCP'], '', ''); trigger_error($message); } -- cgit v1.2.1