Explorar el Código

fix: Fix the day and month comparison so that it is always done using two digits (Closes #48)

Emmanuel Bouthenot hace 11 horas
padre
commit
6615627c9a
Se han modificado 1 ficheros con 2 adiciones y 2 borrados
  1. 2 2
      autopostgresqlbackup

+ 2 - 2
autopostgresqlbackup

@@ -915,10 +915,10 @@ if [ "${ENCRYPTION}" = "yes" ]; then
 fi
 
 log_info "Backup Start: $(date)"
-if [ "${DNOM}" = "${DOMONTHLY}" ]; then
+if [ "${DNOM}" = "${DOMONTHLY#0}" ]; then
     period="monthly"
     rotate="${BRMONTHLY}"
-elif [ "${DNOW}" = "${DOWEEKLY}" ]; then
+elif [ "${DNOW}" = "${DOWEEKLY#0}" ]; then
     period="weekly"
     rotate="${BRWEEKLY}"
 else