aboutsummaryrefslogtreecommitdiffhomepage
path: root/modules/caddyhttp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/caddyhttp')
-rw-r--r--modules/caddyhttp/rewrite/caddyfile.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/caddyhttp/rewrite/caddyfile.go b/modules/caddyhttp/rewrite/caddyfile.go
index 0ce5c41d2..89f44c79b 100644
--- a/modules/caddyhttp/rewrite/caddyfile.go
+++ b/modules/caddyhttp/rewrite/caddyfile.go
@@ -106,7 +106,7 @@ func parseCaddyfileURI(h httpcaddyfile.Helper) (caddyhttp.MiddlewareHandler, err
switch args[0] {
case "strip_prefix":
- if len(args) > 2 {
+ if len(args) != 2 {
return nil, h.ArgErr()
}
rewr.StripPathPrefix = args[1]
@@ -115,7 +115,7 @@ func parseCaddyfileURI(h httpcaddyfile.Helper) (caddyhttp.MiddlewareHandler, err
}
case "strip_suffix":
- if len(args) > 2 {
+ if len(args) != 2 {
return nil, h.ArgErr()
}
rewr.StripPathSuffix = args[1]