More PHP8.4 updates

This commit is contained in:
James Cole
2025-05-04 13:47:00 +02:00
parent e42107c03c
commit 51e86448c7
195 changed files with 524 additions and 715 deletions

View File

@@ -35,14 +35,10 @@ use Illuminate\Support\Facades\Log;
class IsAllowedGroupAction implements ValidationRule
{
private array $acceptedRoles;
private string $className;
private string $methodName;
private UserGroupRepositoryInterface $repository;
private readonly UserGroupRepositoryInterface $repository;
public function __construct(string $className, string $methodName)
public function __construct(private readonly string $className, private readonly string $methodName)
{
$this->className = $className;
$this->methodName = $methodName;
// you need these roles to do anything with any endpoint.
$this->acceptedRoles = [UserRoleEnum::OWNER, UserRoleEnum::FULL];
$this->repository = app(UserGroupRepositoryInterface::class);