mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-01 14:30:32 +02:00
[ticket/13950] Hide undefined permissions
This hides the permissions of the disabled extensions PHPBB3-13950
This commit is contained in:
@@ -159,6 +159,17 @@ class permissions
|
||||
return (isset($this->permissions[$permission]['cat'])) ? $this->permissions[$permission]['cat'] : 'misc';
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if a permission has been defined
|
||||
*
|
||||
* @param string $permission Identifier of the permission
|
||||
* @return bool True if the permission is defined, false otherwise
|
||||
*/
|
||||
public function permission_defined($permission)
|
||||
{
|
||||
return isset($this->permissions[$permission]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the language string of a permission
|
||||
*
|
||||
|
Reference in New Issue
Block a user