Skip to content

Commit

Permalink
more efficient conversion rune to string
Browse files Browse the repository at this point in the history
  • Loading branch information
ldemailly committed Jul 1, 2024
1 parent bab5090 commit 4b32ab6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion logger.go
Original file line number Diff line number Diff line change
Expand Up @@ -618,7 +618,7 @@ func Bool(key string, value bool) KeyVal {

func Rune(key string, value rune) KeyVal {
// Special case otherwise rune is printed as int32 number
return Any(key, fmt.Sprintf("%c", value))
return Any(key, string(value)) // similar to "%c".
}

func (v *KeyVal) StringValue() string {
Expand Down

0 comments on commit 4b32ab6

Please sign in to comment.