From 799dbef0e7012176f6ba94bdecfc10bf7939c0e6 Mon Sep 17 00:00:00 2001 From: Paul Lorenz Date: Tue, 27 Feb 2024 11:43:20 -0500 Subject: [PATCH] Fix create/update of tags from CLI. Fixes #1204 --- ziti/cmd/api/options.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ziti/cmd/api/options.go b/ziti/cmd/api/options.go index d2d68b26a..ca6327a19 100644 --- a/ziti/cmd/api/options.go +++ b/ziti/cmd/api/options.go @@ -21,7 +21,7 @@ import ( "fmt" "github.com/Jeffail/gabs" "github.com/openziti/ziti/ziti/cmd/common" - "github.com/pkg/errors" + "github.com/sirupsen/logrus" "github.com/spf13/cobra" "io" ) @@ -89,9 +89,9 @@ func (self *EntityOptions) AddCommonFlags(cmd *cobra.Command) { func (self *EntityOptions) GetTags() map[string]interface{} { result := map[string]interface{}{} - if len(self.Tags) > 0 { + if len(self.TagsJson) > 0 { if err := json.Unmarshal([]byte(self.TagsJson), &result); err != nil { - panic(errors.Wrap(err, "invalid tags JSON")) + logrus.Fatalf("invalid tags JSON: '%s'", self.TagsJson) } } for k, v := range self.Tags {