From 108c9ad989aeeff143bebf230946a50ae5e8ae3e Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Wed, 17 Oct 2012 17:18:40 +0000 Subject: do not reinvent services::restart_or_start() --- sshd_wizard/Sshd.pm | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'sshd_wizard') diff --git a/sshd_wizard/Sshd.pm b/sshd_wizard/Sshd.pm index cfffc9a2..cac703d8 100755 --- a/sshd_wizard/Sshd.pm +++ b/sshd_wizard/Sshd.pm @@ -213,11 +213,7 @@ sub new { sub write_conf_restart_ssh { $sshd->write_conf($conf); - if (services::is_service_running('sshd')) { - services::restart('sshd'); - } else { - services::start('sshd'); - } + services::restart_or_start('sshd'); } sub global_config { -- cgit v1.2.1