Explorar o código

v-delete-user-backup update #822

Jaap Marcus %!s(int64=5) %!d(string=hai) anos
pai
achega
bdced66b82
Modificáronse 2 ficheiros con 2 adicións e 1 borrados
  1. 1 0
      CHANGELOG.md
  2. 1 1
      bin/v-delete-user-backup

+ 1 - 0
CHANGELOG.md

@@ -33,6 +33,7 @@ All notable changes to this project will be documented in this file.
 - Roundcube fixes for PHP 7.4 compatibility.
 - Added delay when entering wrong username/password/2fa
 - Improved "Forgot password" function prevent brute forcing
+- Update Backup counter propperly when v-delete-user-backup ran
 
 ## [1.1.1] - 2020-03-24 - Hotfix
 ### Features

+ 1 - 1
bin/v-delete-user-backup

@@ -47,7 +47,7 @@ sed -i "/BACKUP='$2' /d" $USER_DATA/backup.conf
 #----------------------------------------------------------#
 
 # Update counter
-U_BACKUPS=$(ls $BACKUP/|grep "^$user."|wc -l)
+U_BACKUPS=$(grep BACKUP $USER_DATA/backup.conf |wc -l)
 update_user_value "$user" '$U_BACKUPS' "$U_BACKUPS"
 
 # Logging