fix: store log_level in var instead in function

Instead of checking multiple times the log level store in Variable.

Signed-off-by: Stephan Wendel <me@stephanwe.de>
This commit is contained in:
Stephan Wendel
2023-02-16 17:21:39 +01:00
parent 541855054f
commit 9a66358443
5 changed files with 37 additions and 36 deletions

View File

@@ -115,9 +115,9 @@ function initial_check {
check_dep "ffmpeg"
check_apps
versioncontrol
# print cfg if ! log_level: quiet
# print cfg if ! "${CROWSNEST_LOG_LEVEL}": quiet
if [ -z "$(check_cfg "${CROWSNEST_CFG}")" ]; then
if [ "$(log_level)" != "quiet" ]; then
if [[ "${CROWSNEST_LOG_LEVEL}" != "quiet" ]]; then
print_cfg
fi
fi