mirror of
https://github.com/caddyserver/caddy.git
synced 2026-01-17 01:30:34 +00:00
caddyfile: Improve Dispenser.NextBlock() to support nesting
This commit is contained in:
@@ -57,7 +57,7 @@ func (s *StaticResponse) UnmarshalCaddyfile(d *caddyfile.Dispenser) error {
|
||||
if d.Args(&statusCodeStr) {
|
||||
s.StatusCode = WeakString(statusCodeStr)
|
||||
}
|
||||
for d.NextBlock() {
|
||||
for d.NextBlock(0) {
|
||||
switch d.Val() {
|
||||
case "body":
|
||||
if s.Body != "" {
|
||||
|
||||
Reference in New Issue
Block a user