Version 5.0.0 beta 1

This commit is contained in:
Neo committed 2025-12-19 16:27:35 -08:00
1 parent 25ddeb65d6
commit 15c7beabc5
6736 files changed
+627902 -497943

No files matched your search

@@ -12,32 +12,37 @@
namespace IPS\forums\extensions\core\Permissions;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
use IPS\Extensions\PermissionsAbstract;
use IPS\forums\Forum;
use function defined;
if ( !defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
header( ( $_SERVER['SERVER_PROTOCOL'] ?? 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
}
/**
* Permissions
*/
class _Permissions
class Permissions extends PermissionsAbstract
{
/**
* Get node classes
*
* @return array
*/
public function getNodeClasses()
public function getNodeClasses(): array
{
return array(
'IPS\forums\Forum' => function( $current, $group )
{
$rows = array();
foreach( \IPS\forums\Forum::roots( NULL ) AS $root )
foreach( Forum::roots( NULL ) AS $root )
{
\IPS\forums\Forum::populatePermissionMatrix( $rows, $root, $group, $current );
Forum::populatePermissionMatrix( $rows, $root, $group, $current );
}
return $rows;