make sure existing_backups array is set in remove_expired_backups function
This commit is contained in:
parent
8fc3322505
commit
193bf8e7c2
|
@ -168,6 +168,10 @@ function bashup::remove_expired_backups () {
|
||||||
# check for and set directory var
|
# check for and set directory var
|
||||||
if [ -n "$1" ]; then
|
if [ -n "$1" ]; then
|
||||||
directory=$1
|
directory=$1
|
||||||
|
# make sure existing_backups array is set
|
||||||
|
if [[ -z $existing_backups ]]; then
|
||||||
|
bashup::set-existing_backups
|
||||||
|
fi
|
||||||
else
|
else
|
||||||
echo "ERROR: directory var not set"
|
echo "ERROR: directory var not set"
|
||||||
return 1
|
return 1
|
||||||
|
|
Loading…
Reference in New Issue
Block a user