recipes2/internal/lib/logger/sl/sl.go

11 lines
145 B
Go
Raw Permalink Normal View History

2024-01-23 12:22:16 +02:00
package sl
import "log/slog"
func Err(err error) slog.Attr {
return slog.Attr{
Key: "error",
Value: slog.StringValue(err.Error()),
}
}