From 2616b6e5438251922fef1dde5de83b57351a0796 Mon Sep 17 00:00:00 2001 From: Dillard Blom Date: Wed, 21 Oct 2026 22:42:43 +0200 Subject: [PATCH] Init guard also counts snapshots in the trash and the catalog as backup data --- lib/Repository/Repository.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Repository/Repository.php b/lib/Repository/Repository.php index 8408e38..2146e20 100644 --- a/lib/Repository/Repository.php +++ b/lib/Repository/Repository.php @@ -75,7 +75,7 @@ final class Repository { // No config, but backup data: the config is missing (or could not be seen just now, a // connection that failed). A new repository here would write a config over the one that // opens this data; refuse instead. - foreach (['index', 'snapshots'] as $dir) { + foreach (['index', 'snapshots', 'trash/snapshots', 'catalog'] as $dir) { if ($backend->listFiles($dir) !== []) { throw new RepositoryException("This location holds backup data ($dir/) but no repository config could be read: not creating a new repository over it. Check the connection and the folder; a missing config can be restored from the recovery kit."); }