anonymous comments shouldn't be allowed in StdLimits
This commit is contained in:
parent
d5c451c4a8
commit
e05f41630b
@ -41,10 +41,8 @@ class PermissionLimits {
|
|||||||
$limits = [];
|
$limits = [];
|
||||||
$perms = Permissions::Perms();
|
$perms = Permissions::Perms();
|
||||||
|
|
||||||
$anon_comments = get_config('system','anonymous_comments',true);
|
|
||||||
|
|
||||||
foreach($perms as $k => $v) {
|
foreach($perms as $k => $v) {
|
||||||
if(strstr($k, 'view') || ($k === 'post_comments' && $anon_comments))
|
if(strstr($k, 'view'))
|
||||||
$limits[$k] = PERMS_PUBLIC;
|
$limits[$k] = PERMS_PUBLIC;
|
||||||
else
|
else
|
||||||
$limits[$k] = PERMS_SPECIFIC;
|
$limits[$k] = PERMS_SPECIFIC;
|
||||||
|
Reference in New Issue
Block a user