AddField adds a log field to the fields in the request context. Not safe for concurrent use.
(ctx context.Context, key string, value any)
| 38 | // AddField adds a log field to the fields in the request context. |
| 39 | // Not safe for concurrent use. |
| 40 | func AddField(ctx context.Context, key string, value any) { |
| 41 | if v, ok := requestFieldsFromContext(ctx); ok { |
| 42 | v.fields[key] = value |
| 43 | } |
| 44 | } |
no test coverage detected