summaryrefslogtreecommitdiff
path: root/modules/caddyhttp/encode
diff options
context:
space:
mode:
authorMatthew Holt <mholt@users.noreply.github.com>2020-02-14 11:00:16 -0700
committerMatthew Holt <mholt@users.noreply.github.com>2020-02-14 11:01:09 -0700
commit15bf9c196c5972051f40ebadf50811bd06e328dd (patch)
tree03362b73a9bdd923bf4f252e346a8441f5de04b0 /modules/caddyhttp/encode
parenteb80165583776d878256359f1635ffa9a17f0171 (diff)
caddyfile: Refactor; NewFromNextSegment(); fix repeated matchers
Now multiple instances of the same matcher can be used within a named matcher without overwriting previous ones.
Diffstat (limited to 'modules/caddyhttp/encode')
-rw-r--r--modules/caddyhttp/encode/caddyfile.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/caddyhttp/encode/caddyfile.go b/modules/caddyhttp/encode/caddyfile.go
index dd12de2..629f0e2 100644
--- a/modules/caddyhttp/encode/caddyfile.go
+++ b/modules/caddyhttp/encode/caddyfile.go
@@ -73,7 +73,7 @@ func (enc *Encode) UnmarshalCaddyfile(d *caddyfile.Dispenser) error {
if !ok {
return fmt.Errorf("encoder module '%s' is not a Caddyfile unmarshaler", mod)
}
- err = unm.UnmarshalCaddyfile(d.NewFromNextTokens())
+ err = unm.UnmarshalCaddyfile(d.NewFromNextSegment())
if err != nil {
return err
}