]> gitweb.hhaalo.de Git - simple-backup.git/commitdiff
fix get backup count
authorBastian Dehn <hhaalo@arcor.de>
Sun, 9 Aug 2026 09:43:19 +0000 (11:43 +0200)
committerBastian Dehn <hhaalo@arcor.de>
Sun, 9 Aug 2026 09:43:19 +0000 (11:43 +0200)
src/backup

index 2ee6fbbbc75761b4248605ab66ff1a17a696fa7b..2fec4b7668894ffc55fa71b76dda0c1c0eff178f 100755 (executable)
@@ -293,7 +293,7 @@ get_backup_count()
        backup_path=$(echo "$config" | jq --raw-output '.backup_path')
        backup_name=$(echo "$config" | jq --raw-output '.backup_name')
 
-       find "$backup_path" -maxdepth 1 -type d 2> /dev/null\
+       find "$backup_path" -mindepth 1 -maxdepth 1 -type d 2> /dev/null\
                | grep --count "$backup_name" \
                || return 0
 }