]> git.mxchange.org Git - friendica.git/commitdiff
Ensuring that only local users can comment on community items
authorMichael <heluecht@pirati.ca>
Thu, 4 Jan 2018 14:39:47 +0000 (14:39 +0000)
committerMichael <heluecht@pirati.ca>
Thu, 4 Jan 2018 14:39:47 +0000 (14:39 +0000)
include/conversation.php

index ff5dc2aed72370204ae41ede6b90aa6f730c2e5c..d6b6bd8eee1a0b05928499ddd773b8c2d66f8ce8 100644 (file)
@@ -619,7 +619,7 @@ function conversation(App $a, $items, $mode, $update, $preview = false) {
                $community_readonly = ($mode === 'community');
 
                // Currently behind a config value. This allows the commenting and sharing of every public item.
-               if (Config::get('system', 'comment_public') && local_user()) {
+               if (Config::get('system', 'comment_public')) {
                        if ($mode === 'community') {
                                $community_readonly = false;
                                $writable = true;
@@ -630,6 +630,10 @@ function conversation(App $a, $items, $mode, $update, $preview = false) {
                        $writable = false;
                }
 
+               if (!local_user()) {
+                       $writable = false;
+               }
+
                if ($mode === 'network-new' || $mode === 'search' || $community_readonly) {
 
                        /*