From 6c1d5f9f39e794d3d1d774fbfa7a3f6722b4edd5 Mon Sep 17 00:00:00 2001 From: WashingtonKK Date: Fri, 22 Mar 2024 16:20:03 +0300 Subject: [PATCH] fix: remove unnecessary type conversion Signed-off-by: WashingtonKK --- opcua/api/logging.go | 2 +- opcua/events/streams.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/opcua/api/logging.go b/opcua/api/logging.go index c104ac2041b..fc728bc9080 100644 --- a/opcua/api/logging.go +++ b/opcua/api/logging.go @@ -177,7 +177,7 @@ func (lm loggingMiddleware) Browse(ctx context.Context, serverURI, namespace, id slog.String("server_uri", serverURI), slog.String("namespace", namespace), slog.String("identifier", identifier), - slog.String("identifierType", identifierType), + slog.String("identifier_type", identifierType), } if err != nil { args = append(args, slog.Any("error", err)) diff --git a/opcua/events/streams.go b/opcua/events/streams.go index de8ca506053..ccee65e7339 100644 --- a/opcua/events/streams.go +++ b/opcua/events/streams.go @@ -156,7 +156,7 @@ func decodeCreateChannel(event map[string]interface{}) (createChannelEvent, erro return createChannelEvent{}, err } var metadata map[string]interface{} - if err := json.Unmarshal([]byte(meta), &metadata); err != nil { + if err := json.Unmarshal(meta, &metadata); err != nil { return createChannelEvent{}, err }