From 15bf9c196c5972051f40ebadf50811bd06e328dd Mon Sep 17 00:00:00 2001 From: Matthew Holt Date: Fri, 14 Feb 2020 11:00:16 -0700 Subject: caddyfile: Refactor; NewFromNextSegment(); fix repeated matchers Now multiple instances of the same matcher can be used within a named matcher without overwriting previous ones. --- caddyconfig/httpcaddyfile/options.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'caddyconfig/httpcaddyfile/options.go') diff --git a/caddyconfig/httpcaddyfile/options.go b/caddyconfig/httpcaddyfile/options.go index 9ebefea..fdecfa4 100644 --- a/caddyconfig/httpcaddyfile/options.go +++ b/caddyconfig/httpcaddyfile/options.go @@ -151,7 +151,7 @@ func parseOptStorage(d *caddyfile.Dispenser) (caddy.StorageConverter, error) { if !ok { return nil, fmt.Errorf("storage module '%s' is not a Caddyfile unmarshaler", mod.ID) } - err = unm.UnmarshalCaddyfile(d.NewFromNextTokens()) + err = unm.UnmarshalCaddyfile(d.NewFromNextSegment()) if err != nil { return nil, err } -- cgit v1.2.3