Skip to content

Commit 3782759

Browse files
arckadiousPierre PERRIER-RIDET
andauthored
Fix logging Example : log only first field (#694)
Co-authored-by: Pierre PERRIER-RIDET <[email protected]>
1 parent c2940ba commit 3782759

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

interceptors/logging/examples/logrus/example_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ func InterceptorLogger(l logrus.FieldLogger) logging.Logger {
1818
return logging.LoggerFunc(func(_ context.Context, lvl logging.Level, msg string, fields ...any) {
1919
f := make(map[string]any, len(fields)/2)
2020
i := logging.Fields(fields).Iterator()
21-
if i.Next() {
21+
for i.Next() {
2222
k, v := i.At()
2323
f[k] = v
2424
}

0 commit comments

Comments
 (0)