Skip to content

Commit

Permalink
feat: add read debug headers directive.
Browse files Browse the repository at this point in the history
  • Loading branch information
vuongxuongminh committed Apr 21, 2022
1 parent ce6842d commit 21ecebd
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions caddyfile_caching.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,18 @@ func (h *Handler) unmarshalCaddyfileCaching(d *caddyfile.Dispenser) error {
}

caching.AutoInvalidate = val
case "debug_headers":
if !d.NextArg() {
return d.ArgErr()
}

val, err := strconv.ParseBool(d.Val())

if err != nil {
return err
}

caching.DebugHeaders = val
default:
return d.Errf("unrecognized subdirective %s", d.Val())
}
Expand Down

0 comments on commit 21ecebd

Please sign in to comment.