/** * @return int */ private function getSchedulerTaskUid() { foreach ($this->scheduler->fetchTasksWithCondition() as $task) { if ($task instanceof Tx_FeatureFlag_System_Typo3_Task_FlagEntries) { $taskUid = $task->getTaskUid(); } } if (null === $taskUid) { throw new RuntimeException('scheduler task for feature_flag was not found'); } return $taskUid; }