mirror of
https://github.com/caddyserver/caddy.git
synced 2025-05-30 15:58:10 +08:00
core: Variadic Context.Logger(); soft deprecation
Ideally I'd just remove the parameter to caddy.Context.Logger(), but this would break most Caddy plugins. Instead, I'm making it variadic and marking it as partially deprecated. In the future, I might completely remove the parameter once most plugins have updated.
This commit is contained in:
@ -61,7 +61,7 @@ func (Handler) CaddyModule() caddy.ModuleInfo {
|
||||
|
||||
// Provision sets up h.
|
||||
func (h *Handler) Provision(ctx caddy.Context) error {
|
||||
h.logger = ctx.Logger(h)
|
||||
h.logger = ctx.Logger()
|
||||
if h.Headers != nil {
|
||||
err := h.Headers.Provision(ctx)
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user