diff --git a/bash/log.sh b/bash/log.sh index f7d325e..5bb7906 100644 --- a/bash/log.sh +++ b/bash/log.sh @@ -7,14 +7,14 @@ LOG_LEVEL_TRACE=5 LOG_LEVEL=${LOG_LEVEL_WARN} -function log_fatal { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_FATAL} ] && echo "${@}" ; } +log_fatal() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_FATAL}" ] && echo "${@}" ; } -function log_error { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_ERROR} ] && echo "${@}" ; } +log_error() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_ERROR}" ] && echo "${@}" ; } -function log_warn { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_WARN} ] && echo "${@}" ; } +log_warn() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_WARN}" ] && echo "${@}" ; } -function log_info { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_INFO} ] && echo "${@}" ; } +log_info() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_INFO}" ] && echo "${@}" ; } -function log_debug { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_DEBUG} ] && echo "${@}" ; } +log_debug() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_DEBUG}" ] && echo "${@}" ; } -function log_trace { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_TRACE} ] && echo "${@}" ; } +log_trace() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_TRACE}" ] && echo "${@}" ; }