diff --git a/src/Bundle/ChillTaskBundle/Timeline/SingleTaskTaskLifeCycleEventTimelineProvider.php b/src/Bundle/ChillTaskBundle/Timeline/SingleTaskTaskLifeCycleEventTimelineProvider.php index 3ee3b1129..a07a8c9e3 100644 --- a/src/Bundle/ChillTaskBundle/Timeline/SingleTaskTaskLifeCycleEventTimelineProvider.php +++ b/src/Bundle/ChillTaskBundle/Timeline/SingleTaskTaskLifeCycleEventTimelineProvider.php @@ -17,7 +17,7 @@ use Chill\TaskBundle\Entity\SingleTask; use Chill\TaskBundle\Entity\Task\SingleTaskPlaceEvent; use Doctrine\ORM\EntityManagerInterface; use Symfony\Component\Workflow\Registry; -use Symfony\Component\Workflow\Workflow; +use Symfony\Component\Workflow\WorkflowInterface; /** * Provide timeline elements related to tasks, in tasks context. @@ -108,12 +108,7 @@ class SingleTaskTaskLifeCycleEventTimelineProvider implements TimelineProviderIn return self::TYPE === $type; } - /** - * @param string $name - * - * @return \Symfony\Component\Workflow\Transition - */ - protected function getTransitionByName($name, Workflow $workflow) + protected function getTransitionByName(string $name, WorkflowInterface $workflow) { foreach ($workflow->getDefinition()->getTransitions() as $transition) { if ($transition->getName() === $name) { diff --git a/src/Bundle/ChillTaskBundle/Timeline/TaskLifeCycleEventTimelineProvider.php b/src/Bundle/ChillTaskBundle/Timeline/TaskLifeCycleEventTimelineProvider.php index ee1fa3a82..221a2056e 100644 --- a/src/Bundle/ChillTaskBundle/Timeline/TaskLifeCycleEventTimelineProvider.php +++ b/src/Bundle/ChillTaskBundle/Timeline/TaskLifeCycleEventTimelineProvider.php @@ -21,7 +21,7 @@ use Chill\TaskBundle\Entity\Task\SingleTaskPlaceEvent; use Doctrine\ORM\EntityManagerInterface; use Symfony\Bundle\SecurityBundle\Security; use Symfony\Component\Workflow\Registry; -use Symfony\Component\Workflow\Workflow; +use Symfony\Component\Workflow\WorkflowInterface; /** * Provide element for timeline for 'person' and 'center' context. @@ -94,12 +94,7 @@ class TaskLifeCycleEventTimelineProvider implements TimelineProviderInterface return self::TYPE === $type; } - /** - * @param string $name - * - * @return \Symfony\Component\Workflow\Transition - */ - protected function getTransitionByName($name, Workflow $workflow) + protected function getTransitionByName(string $name, WorkflowInterface $workflow) { foreach ($workflow->getDefinition()->getTransitions() as $transition) { if ($transition->getName() === $name) {