mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-07-23 04:14:36 +02:00
Fixed some more psalm issues.
This commit is contained in:
parent
cb0aa7bc7a
commit
a28e81065f
11 changed files with 25 additions and 18 deletions
|
@ -62,12 +62,12 @@ class PermissionResolver
|
|||
/**
|
||||
* PermissionResolver constructor.
|
||||
*/
|
||||
public function __construct(ContainerInterface $container)
|
||||
public function __construct(bool $kernel_debug, string $kernel_cache_dir)
|
||||
{
|
||||
$cache_dir = $container->getParameter('kernel.cache_dir');
|
||||
$cache_dir = $kernel_cache_dir;
|
||||
//Here the cached structure will be saved.
|
||||
$this->cache_file = $cache_dir.'/permissions.php.cache';
|
||||
$this->is_debug = $container->getParameter('kernel.debug');
|
||||
$this->is_debug = $kernel_debug;
|
||||
|
||||
$this->permission_structure = $this->generatePermissionStructure();
|
||||
|
||||
|
@ -127,7 +127,7 @@ class PermissionResolver
|
|||
return $allowed;
|
||||
}
|
||||
|
||||
/** @var HasPermissionsInterface $parent */
|
||||
/** @var Group $parent */
|
||||
$parent = $user->getGroup();
|
||||
while (null !== $parent) { //The top group, has parent == null
|
||||
//Check if our current element gives a info about disallow/allow
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue