From f0bd58cbf5afb23795cede62b6c13677a8850f7a Mon Sep 17 00:00:00 2001 From: Mmx <1624045573@qq.com> Date: Fri, 26 Nov 2021 08:41:34 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=89=8D=E5=8F=B0=E8=BF=90=E8=A1=8C?= =?UTF-8?q?=E4=BC=9A=E9=80=80=E5=87=BA=E5=90=8E=E5=8F=B0=E7=A8=8B=E5=BA=8F?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- controllers/guardian.go | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/controllers/guardian.go b/controllers/guardian.go index c715b5b..ebe07c0 100644 --- a/controllers/guardian.go +++ b/controllers/guardian.go @@ -11,10 +11,12 @@ import ( func Guardian(output bool) { util.Log.OutPut = output - go Daemon.DaemonChan() + if global.Config.Settings.Daemon.Enable { + go Daemon.DaemonChan() - if e := Daemon.MarkDaemon(); e != nil { - util.Log.Fatalln(e) + if e := Daemon.MarkDaemon(); e != nil { + util.Log.Fatalln(e) + } } var c = make(chan bool)