taskWorkflowManager = $taskWorkflowManager; } public function getFunctions() { return [ new TwigFunction('task_workflow_metadata', [$this, 'getWorkflowMetadata']), ]; } public function getWorkflowMetadata( AbstractTask $task, string $key, $metadataSubject = null, ?string $name = null ) { return $this->taskWorkflowManager->getWorkflowMetadata($task, $key, $metadataSubject, $name); } }