aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/ucp/ucp_main.php
diff options
context:
space:
mode:
authorJoas Schilling <nickvergessen@gmx.de>2013-07-11 14:24:07 +0200
committerJoas Schilling <nickvergessen@gmx.de>2013-07-11 14:24:07 +0200
commit9aed758c1397c31b979f4aca51249c73d21bd6f5 (patch)
tree03c13aa87f3aa0ca892fe8bca937d2de7054bff5 /phpBB/includes/ucp/ucp_main.php
parent9f89cb4cfbbd46ad45a9c7942fc2233b489bb076 (diff)
downloadforums-9aed758c1397c31b979f4aca51249c73d21bd6f5.tar
forums-9aed758c1397c31b979f4aca51249c73d21bd6f5.tar.gz
forums-9aed758c1397c31b979f4aca51249c73d21bd6f5.tar.bz2
forums-9aed758c1397c31b979f4aca51249c73d21bd6f5.tar.xz
forums-9aed758c1397c31b979f4aca51249c73d21bd6f5.zip
[ticket/9657] Use the service instead of the static class
PHPBB3-9657
Diffstat (limited to 'phpBB/includes/ucp/ucp_main.php')
-rw-r--r--phpBB/includes/ucp/ucp_main.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/phpBB/includes/ucp/ucp_main.php b/phpBB/includes/ucp/ucp_main.php
index 7aa06464b7..615b567134 100644
--- a/phpBB/includes/ucp/ucp_main.php
+++ b/phpBB/includes/ucp/ucp_main.php
@@ -642,7 +642,7 @@ class ucp_main
*/
function assign_topiclist($mode = 'subscribed', $forbidden_forum_ary = array())
{
- global $user, $db, $template, $config, $cache, $auth, $phpbb_root_path, $phpEx;
+ global $user, $db, $template, $config, $cache, $auth, $phpbb_root_path, $phpEx, $phpbb_container;
$table = ($mode == 'subscribed') ? TOPICS_WATCH_TABLE : BOOKMARKS_TABLE;
$start = request_var('start', 0);
@@ -768,6 +768,8 @@ class ucp_main
}
}
+ $phpbb_content_visibility = $phpbb_container->get('content.visibility');
+
foreach ($topic_list as $topic_id)
{
$row = &$rowset[$topic_id];
@@ -778,7 +780,7 @@ class ucp_main
$unread_topic = (isset($topic_tracking_info[$topic_id]) && $row['topic_last_post_time'] > $topic_tracking_info[$topic_id]) ? true : false;
// Replies
- $replies = phpbb_content_visibility::get_count('topic_posts', $row, $forum_id) - 1;
+ $replies = $phpbb_content_visibility->get_count('topic_posts', $row, $forum_id) - 1;
if ($row['topic_status'] == ITEM_MOVED && !empty($row['topic_moved_id']))
{