diff --git a/phpBB/phpbb/content_visibility.php b/phpBB/phpbb/content_visibility.php index 1c69691a2c..276a9d9d23 100644 --- a/phpBB/phpbb/content_visibility.php +++ b/phpBB/phpbb/content_visibility.php @@ -146,11 +146,11 @@ class content_visibility { $visibility = $data[$mode . '_visibility']; $poster_key = ($mode === 'topic') ? 'topic_poster' : 'poster_id'; - $is_visible = $this->auth->acl_get('m_approve', $forum_id) || - ($visibility == ITEM_APPROVED) || - ($this->config['display_unapproved_posts'] && - ($this->user->data['user_id'] <> ANONYMOUS) && - ($visibility == ITEM_UNAPPROVED || $visibility == ITEM_REAPPROVE) && + $is_visible = $this->auth->acl_get('m_approve', $forum_id) || + ($visibility == ITEM_APPROVED) || + ($this->config['display_unapproved_posts'] && + ($this->user->data['user_id'] <> ANONYMOUS) && + ($visibility == ITEM_UNAPPROVED || $visibility == ITEM_REAPPROVE) && ($this->user->data['user_id'] === $data[$poster_key]) ); diff --git a/phpBB/viewforum.php b/phpBB/viewforum.php index 6b98021e3c..787667fcd7 100644 --- a/phpBB/viewforum.php +++ b/phpBB/viewforum.php @@ -899,8 +899,8 @@ if (count($topic_list)) // Replies $replies = $phpbb_content_visibility->get_count('topic_posts', $row, $topic_forum_id) - 1; - //correct for case of unapproved topic visible to poster - a bit dirty but efficient - if ($replies < 0) + //correct for case of unapproved topic visible to poster - a bit dirty but efficient + if ($replies < 0) { $replies = 0; }