From ba712113820fde70336c5f7faee24a80b0b121f0 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Mon, 4 Sep 2023 14:35:33 +0100 Subject: [PATCH] refactor: dont try to stop a server that is already stopped --- lgsm/modules/command_stop.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lgsm/modules/command_stop.sh b/lgsm/modules/command_stop.sh index 5fc48c828..409e57b14 100644 --- a/lgsm/modules/command_stop.sh +++ b/lgsm/modules/command_stop.sh @@ -260,11 +260,11 @@ fn_stop_pre_check() { else # Select graceful shutdown. fn_stop_graceful_select - fi - # Check status again, a kill tmux session if graceful shutdown failed. - check_status.sh - if [ "${status}" != "0" ]; then - fn_stop_tmux + # Check status again, a kill tmux session if graceful shutdown failed. + check_status.sh + if [ "${status}" != "0" ]; then + fn_stop_tmux + fi fi }