Keep up to 10 database backups

Signed-off-by: DL6ER <dl6er@dl6er.de>
This commit is contained in:
DL6ER 2024-11-16 12:08:27 +01:00
parent a5cb07c76e
commit fdf44355d2
No known key found for this signature in database
GPG key ID: 00135ACBD90B28DD

View file

@ -425,14 +425,14 @@ gravity_DownloadBlocklists() {
echo -e "\\n ${CROSS} Unable to copy data from ${gravityDBfile} to ${gravityTEMPfile}\\n ${output}" echo -e "\\n ${CROSS} Unable to copy data from ${gravityDBfile} to ${gravityTEMPfile}\\n ${output}"
# Try to attempt a backup restore # Try to attempt a backup restore
for i in {1..9}; do for i in {1..10}; do
if try_restore_backup "${i}"; then if try_restore_backup "${i}"; then
break break
fi fi
done done
# If none of the attempts worked, return 1 # If none of the attempts worked, return 1
if [[ "${i}" -eq 9 ]]; then if [[ "${i}" -eq 10 ]]; then
return 1 return 1
fi fi