fix(RESTORE): strip trailing slash from backup-location

This commit is contained in:
Asif Bacchus 2021-02-08 10:31:03 -07:00
parent 78e1ed2539
commit 7b3ff7f6ae
1 changed files with 1 additions and 1 deletions

View File

@ -202,7 +202,7 @@ while [ $# -gt 0 ]; do
-b|--backup-location)
if [ -n "$2" ]; then
if [ -d "$2" ] && [ -n "$( ls -A "$2" )" ]; then
backupLocation="$2"
backupLocation="${2%/}"
shift
else
consoleError '1' "$1: cannot find specified backup location directory or it is empty."