1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-31 22:10:45 +02:00

[ticket/10237] Display login-box for guests, when (un)subscribing

Also initialise $is_watching for PHP Notice: Undefined variable is_watching

PHPBB3-10237
This commit is contained in:
Joas Schilling
2011-07-20 00:55:49 +02:00
parent d60ffdd55c
commit 1a19388aa3
3 changed files with 19 additions and 9 deletions

View File

@@ -486,9 +486,10 @@ $s_watching_topic = array(
'is_watching' => false,
);
if (($config['email_enable'] || $config['jab_enable']) && $config['allow_topic_notify'] && $user->data['is_registered'])
if (($config['email_enable'] || $config['jab_enable']) && $config['allow_topic_notify'])
{
watch_topic_forum('topic', $s_watching_topic, $user->data['user_id'], $forum_id, $topic_id, $topic_data['notify_status'], $start, $topic_data['topic_title']);
$notify_status = (isset($topic_data['notify_status'])) ? $topic_data['notify_status'] : null;
watch_topic_forum('topic', $s_watching_topic, $user->data['user_id'], $forum_id, $topic_id, $notify_status, $start, $topic_data['topic_title']);
// Reset forum notification if forum notify is set
if ($config['allow_forum_notify'] && $auth->acl_get('f_subscribe', $forum_id))