Hello Support,
I'm writing because I've found sth weird on last Cobalt version.
On file "components\com_cobalt\library\php\helpers\access.php", the method allowHide is written as follows:
public static function allowHide($record, $type, $section)
{
$user = JFactory::getUser();
if($type->params->get('properties.allow_hide') && $record->user_id && ($record->user_id == $user->get('id')))
{
return TRUE;
}
return FALSE;
}
This wouldn't allow any moderator to use that feature, in other words, it's just the author the one that can set the record as hidden or not.
I've checked Cobalt 7 access file and the method considered the fact that an administrator could hide any record.
On Cobalt 7:
public static function allowHide($record, $type, $section)
{
$user = JFactory::getUser();
if(in_array($type->params->get('properties.item_can_moderate'), $user->getAuthorisedViewLevels()))
{
return TRUE;
}
if($type->params->get('properties.allow_hide') && $record->user_id && ($record->user_id == $user->get('id')))
{
return TRUE;
}
return FALSE;
}
Is this some kind of unnoticed problem or is it intentional? Personally, I believe it's quite better to let moderators hide or unhide records.
Thanks,
Matias
Hello Support,
I'm writing because I've found sth weird on last Cobalt version.
On file "components\com_cobalt\library\php\helpers\access.php", the method allowHide is written as follows:
This wouldn't allow any moderator to use that feature, in other words, it's just the author the one that can set the record as hidden or not. I've checked Cobalt 7 access file and the method considered the fact that an administrator could hide any record. On Cobalt 7:
Is this some kind of unnoticed problem or is it intentional? Personally, I believe it's quite better to let moderators hide or unhide records.
Thanks, Matias