mirror of
https://github.com/caddyserver/caddy.git
synced 2024-11-25 09:40:13 +08:00
httpcaddyfile: Improve unrecognized directive errors
This commit is contained in:
parent
f70a7578fa
commit
bfbc459c0a
|
@ -329,7 +329,7 @@ func parseSegmentAsConfig(h Helper) ([]ConfigValue, error) {
|
||||||
dir := seg.Directive()
|
dir := seg.Directive()
|
||||||
dirFunc, ok := registeredDirectives[dir]
|
dirFunc, ok := registeredDirectives[dir]
|
||||||
if !ok {
|
if !ok {
|
||||||
return nil, h.Errf("unrecognized directive: %s", dir)
|
return nil, h.Errf("unrecognized directive: %s - are you sure your Caddyfile structure (nesting and braces) is correct?", dir)
|
||||||
}
|
}
|
||||||
|
|
||||||
subHelper := h
|
subHelper := h
|
||||||
|
|
Loading…
Reference in New Issue
Block a user