Fix unbound variable errors

This commit is contained in:
2022-06-02 16:08:07 +02:00
parent a6eeccb417
commit 4f8c1b5388
15 changed files with 85 additions and 86 deletions

View File

@@ -25,9 +25,9 @@ seq_config() {
initSeqConfig "$CONFIG_FILE_NAME" "$CONFIG_FILE_TEMPLATE"
if [ $? -eq 0 ] ; then
CONFIG=1
postgresDb="$MAYAN_DB"
postgresUser="$MAYAN_DBUSER"
postgresPass="$MAYAN_DBPASS"
postgresDb="${MAYAN_DB:-}"
postgresUser="${MAYAN_DBUSER:-}"
postgresPass="${MAYAN_DBPASS:-}"
else
# End if no configuration file exists
dry || return -1
@@ -223,7 +223,7 @@ readDatabaseInfos() {
# Needs readDatabaseInfos() to execute some commands
toolScript() {
if [ ! -z "$1" ] ; then
if [ -n "${1:-}" ] ; then
readDatabaseInfos
fi