Commit c2b9209e authored by Cristian Weiland's avatar Cristian Weiland

Issue #68: Fix bug in variable checking

Signed-off-by: Cristian Weiland's avatarCristian Weiland <cw14@inf.ufpr.br>
parent 04d42b25
......@@ -21,16 +21,16 @@ fi
source ./config.sh
# Check if all variables in config file are set:
if [ -z ${index} ]; then
if [ -z "${index}" ]; then
echo "Var 'index' is unset. Set it in file 'scripts/expenses/config.sh'.";
exit;
fi
if [ -z ${host} ]; then
if [ -z "${host}" ]; then
echo "Var 'host' is unset. Set it in file 'scripts/expenses/config.sh'.";
exit;
fi
if [ -z ${columnName} ]; then
echo "Var 'host' is unset. Set it in file 'scripts/expenses/config.sh'.";
if [ -z "${columnName}" ]; then
echo "Var 'columnName' is unset. Set it in file 'scripts/expenses/config.sh'.";
exit;
fi
......
......@@ -20,15 +20,15 @@ fi
source ./config.sh
# Check if all variables in config file are set:
if [ -z ${index} ]; then
if [ -z "${index}" ]; then
echo "Var 'index' is unset. Set it in file 'scripts/travel_allowance/config.sh'.";
exit;
fi
if [ -z ${host} ]; then
if [ -z "${host}" ]; then
echo "Var 'host' is unset. Set it in file 'scripts/travel_allowance/config.sh'.";
exit;
fi
if [ -z ${columnName} ]; then
if [ -z "${columnName}" ]; then
echo "Var 'host' is unset. Set it in file 'scripts/travel_allowance/config.sh'.";
exit;
fi
......
......@@ -23,15 +23,15 @@ fi
source ./config.sh
if [ -z ${index} ]; then
if [ -z "${index}" ]; then
echo "Var 'index' is unset. Set it in file 'scripts/workers/config.sh'.";
exit;
fi
if [ -z ${host} ]; then
if [ -z "${host}" ]; then
echo "Var 'host' is unset. Set it in file 'scripts/workers/config.sh'.";
exit;
fi
if [ -z ${columnName} ]; then
if [ -z "${columnName}" ]; then
echo "Var 'columnName' is unset. Set it in file 'scripts/workers/config.sh'.";
exit;
fi
......
Markdown is supported
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