*/ public array $futurePersonSignatures = []; /** * An eventual user which is requested to apply a signature. */ public ?User $futureUserSignature = null; public ?Transition $transition = null; public string $comment = ''; public function __construct( public EntityWorkflow $entityWorkflow ) {} #[Assert\Callback()] public function validateCCUserIsNotInDest(ExecutionContextInterface $context, $payload): void { foreach ($this->futureDestUsers as $u) { if (in_array($u, $this->futureCcUsers, true)) { $context ->buildViolation('workflow.The user in cc cannot be a dest user in the same workflow step') ->atPath('ccUsers') ->addViolation(); } } } }