mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-22 23:53:50 +00:00
apply rules rector up to php82
This commit is contained in:
@@ -29,12 +29,12 @@ use function call_user_func;
|
||||
*/
|
||||
class IdToEntityDataTransformer implements DataTransformerInterface
|
||||
{
|
||||
private Closure $getId;
|
||||
private readonly Closure $getId;
|
||||
|
||||
/**
|
||||
* @param Closure $getId
|
||||
*/
|
||||
public function __construct(private ObjectRepository $repository, private bool $multiple = false, ?callable $getId = null)
|
||||
public function __construct(private readonly ObjectRepository $repository, private readonly bool $multiple = false, ?callable $getId = null)
|
||||
{
|
||||
$this->getId = $getId ?? static fn (object $o) => $o->getId();
|
||||
}
|
||||
|
Reference in New Issue
Block a user