entityWorkflowManager->findByRelatedEntity($entity); $currentUser = $this->security->getUser(); foreach ($workflows as $workflow) { if ($workflow->isFinal()) { return false; } if ($workflow->getCurrentStep()->getAllDestUser()->contains($currentUser)) { return true; } } return true; } }