Enabled reports whether the handler handles records at the given level. The handler ignores records whose level is lower.
(ctx context.Context, level slog.Level)
| 91 | // |
| 92 | // The handler ignores records whose level is lower. |
| 93 | func (h *BatchHandler) Enabled(ctx context.Context, level slog.Level) bool { |
| 94 | return level >= h.options.Level.Level() |
| 95 | } |
| 96 | |
| 97 | // WithGroup returns a new BatchHandler that starts a group. |
| 98 | // |
no outgoing calls