Skip to content

Commit

Permalink
#401 fix missing value in label method (#402)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhangzhonglai authored Jan 21, 2022
1 parent 5a62194 commit e310f73
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions core/shared/src/main/scala/zio/logging/LogFormat.scala
Original file line number Diff line number Diff line change
Expand Up @@ -243,12 +243,12 @@ object LogFormat {
}

def label(label: => String, value: LogFormat): LogFormat =
LogFormat.make { (builder, _, _, _, _, _, _, _) =>
LogFormat.make { (builder, trace, fiberId, logLevel, message, context, spans, location) =>
builder.openKey()
try builder.appendText(label)
finally builder.closeKeyOpenValue()

try value.unsafeFormat(builder)
try value.unsafeFormat(builder)(trace, fiberId, logLevel, message, context, spans, location)
finally builder.closeValue()
}

Expand Down

0 comments on commit e310f73

Please sign in to comment.