Skip to content
Snippets Groups Projects
Commit 420c12de authored by Brandon Rodriguez's avatar Brandon Rodriguez
Browse files

Minor correction to backup script

parent 7bc8ee99
Branches
No related merge requests found
...@@ -131,6 +131,14 @@ function validate_args () { ...@@ -131,6 +131,14 @@ function validate_args () {
get_absolute_path "${kwargs[backup_path]}" get_absolute_path "${kwargs[backup_path]}"
backup_folder="${return_value}" backup_folder="${return_value}"
fi fi
# Validate backup folder.
if [[ ! -d ${backup_folder} ]]
then
echo -e "${text_red}Provided backup location is not a folder, or does not exist.${text_reset}"
echo -e "${text_red}Please verify the location exists, and that the location points to a folder, not a file.${text_reset}"
exit 0
fi
} }
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment