/** * @inheritdoc * * @return bool */ public function isCancelled() { if ($this->task instanceof Cancellable) { return $this->task->isCancelled(); } return false; }
/** * Check if the given task is cancelled. * * @param Task $task * * @return bool */ private function isTaskCancelled(Task $task) { if ($task instanceof Cancellable) { return $task->isCancelled(); } return false; }