]> git.mxchange.org Git - friendica.git/blobdiff - mod/community.php
Merge pull request #5259 from rabuzarus/20180616_-_magic_auth_test_2
[friendica.git] / mod / community.php
index 88fc6168bbbe8041091e4a83878a53c9c54ab216..59be7487bdca55a8318410b80e4eeab16f2dc199 100644 (file)
@@ -2,8 +2,10 @@
 /**
  * @file mod/community.php
  */
+
 use Friendica\App;
 use Friendica\Content\Nav;
+use Friendica\Core\ACL;
 use Friendica\Core\Config;
 use Friendica\Core\L10n;
 use Friendica\Core\PConfig;
@@ -28,6 +30,11 @@ function community_content(App $a, $update = 0)
 
        $page_style = Config::get('system', 'community_page_style');
 
+       if ($page_style == CP_NO_INTERNAL_COMMUNITY) {
+               notice(L10n::t('Access denied.') . EOL);
+               return;
+       }
+
        if ($a->argc > 1) {
                $content = $a->argv[1];
        } else {
@@ -104,7 +111,7 @@ function community_content(App $a, $update = 0)
                                'default_location' => $a->user['default-location'],
                                'nickname' => $a->user['nickname'],
                                'lockstate' => (is_array($a->user) && (strlen($a->user['allow_cid']) || strlen($a->user['allow_gid']) || strlen($a->user['deny_cid']) || strlen($a->user['deny_gid'])) ? 'lock' : 'unlock'),
-                               'acl' => populate_acl($a->user, true),
+                               'acl' => ACL::getFullSelectorHTML($a->user, true),
                                'bang' => '',
                                'visitor' => 'block',
                                'profile_uid' => local_user(),
@@ -164,7 +171,7 @@ function community_content(App $a, $update = 0)
                $s = $r;
        }
 
-       $o .= conversation($a, $s, 'community', $update);
+       $o .= conversation($a, $s, 'community', $update, false, 'commented', local_user());
 
        if (!$update) {
                $o .= alt_pager($a, count($r));