From 60e76d755df034e9c0d44de75d5e3528637e25ed Mon Sep 17 00:00:00 2001 From: Cyberes Date: Sat, 30 Mar 2024 20:51:43 -0600 Subject: [PATCH] fix --- check_systemd_service.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/check_systemd_service.sh b/check_systemd_service.sh index 8147906..9cb4434 100755 --- a/check_systemd_service.sh +++ b/check_systemd_service.sh @@ -71,7 +71,7 @@ current_time=$(date +%s) start_time_diff="undefined" end_time_diff="undefined" -if [ -n "$start_time" ]; then +if [ -n "$start_time" ] && [ "$start_time" != "n/a" ]; then start_time_diff=$((current_time - $(date -d "$start_time" +%s))) start_time_diff_perf="| uptime=${start_time_diff}s" fi