diff --git a/src/Commands/Backup/RestoreCommand.php b/src/Commands/Backup/RestoreCommand.php index 3a2f11667..49bc24db6 100644 --- a/src/Commands/Backup/RestoreCommand.php +++ b/src/Commands/Backup/RestoreCommand.php @@ -88,7 +88,10 @@ protected function doGetBackups(string $site_env, array $elements, array $option foreach ($elements as $element) { $options['element'] = $element; try { - $backups[$element] = $this->getBackup($site_env, $options); + $backup = $this->getBackup($site_env, $options); + if ($backup->get('type') === $element) { + $backups[$element] = $backup; + } } catch (TerminusNotFoundException $e) { continue; }