private function getTransitionWithNullCheck($name) { $transition = $this->getTransition($name); if ($transition === null) { throw new Exception(sprintf("transition not found for '%s'", $name), Exception::SM_NO_TRANSITION_FOUND); } return $transition; }