From 35311010a60058d1eb0db7389361d990d390bd68 Mon Sep 17 00:00:00 2001 From: cnlh Date: Tue, 7 Jan 2020 10:02:58 +0800 Subject: [PATCH] fixed #354 --- cmd/npc/npc.go | 2 +- cmd/nps/nps.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cmd/npc/npc.go b/cmd/npc/npc.go index da29a05..ea1a5ec 100644 --- a/cmd/npc/npc.go +++ b/cmd/npc/npc.go @@ -114,7 +114,7 @@ func main() { } err := service.Control(s, os.Args[1]) if err != nil { - logs.Error("Valid actions: %q\n", service.ControlAction, err.Error()) + logs.Error("Valid actions: %q\n%s", service.ControlAction, err.Error()) } return } diff --git a/cmd/nps/nps.go b/cmd/nps/nps.go index 306da88..36141f0 100644 --- a/cmd/nps/nps.go +++ b/cmd/nps/nps.go @@ -94,13 +94,13 @@ func main() { } err = service.Control(s, os.Args[1]) if err != nil { - logs.Error("Valid actions: %q\n", service.ControlAction, err.Error()) + logs.Error("Valid actions: %q\n%s", service.ControlAction, err.Error()) } return case "start", "restart", "stop", "uninstall": err := service.Control(s, os.Args[1]) if err != nil { - logs.Error("Valid actions: %q\n", service.ControlAction, err.Error()) + logs.Error("Valid actions: %q\n%s", service.ControlAction, err.Error()) } return case "update":