/** * Bypasses failed backup in restore process. * * @param RestoreEvent $event */ public function onRestoreStarted(RestoreEvent $event) { $database = $event->getDatabase(); if ($database->getWithDefault('state', BackupStatus::STATE_SUCCESS) === BackupStatus::STATE_FAILED) { $this->output->writeln(' <info>Bypassed</info>'); $event->stopPropagation(); } }