From 626c6736b14a902715fc914a94ce72681aa7e46e Mon Sep 17 00:00:00 2001 From: Asif Bacchus Date: Fri, 7 Sep 2018 04:33:59 -0600 Subject: [PATCH] checkExist: removed 'verify' command, redundant to 'find' --- root/scripts/borgbackup.sh | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/root/scripts/borgbackup.sh b/root/scripts/borgbackup.sh index d04bce9..20c0a00 100755 --- a/root/scripts/borgbackup.sh +++ b/root/scripts/borgbackup.sh @@ -225,20 +225,8 @@ function checkExist { # file not found, return proper code return 5 fi - elif [ "$1" = "verify" ]; then - if [ -e "$2" ]; then - echo -e "\e[0m[`date +%Y-%m-%d` `date +%H:%M:%S`] Confirmed:" \ - "\e[0;33m${2}\e[0m" >> $logFileVerbose - return 0 - else - echo -e "\e[1;31m[`date +%Y-%m-%d` `date +%H:%M:%S`] --ERROR:" \ - "Problem creating ${2}--\e[0m" >> $logFile - cleanUp 503 - cleanUp sqlDump - quit 102 - fi - else - # this code shouldn't be executed, provide checkable return code + else + # this code shouldn't be executed, provide checkable return code return 200 fi }