aboutsummaryrefslogtreecommitdiffhomepage
path: root/modules/caddyhttp/vars.go
diff options
context:
space:
mode:
Diffstat (limited to 'modules/caddyhttp/vars.go')
-rw-r--r--modules/caddyhttp/vars.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/modules/caddyhttp/vars.go b/modules/caddyhttp/vars.go
index 77e06e3cb..280843e70 100644
--- a/modules/caddyhttp/vars.go
+++ b/modules/caddyhttp/vars.go
@@ -207,6 +207,11 @@ func (m VarsMatcher) Match(r *http.Request) bool {
return false
}
+// MatchWithError returns true if r matches m.
+func (m VarsMatcher) MatchWithError(r *http.Request) (bool, error) {
+ return m.Match(r), nil
+}
+
// CELLibrary produces options that expose this matcher for use in CEL
// expression matchers.
//
@@ -328,6 +333,11 @@ func (m MatchVarsRE) Match(r *http.Request) bool {
return false
}
+// MatchWithError returns true if r matches m.
+func (m MatchVarsRE) MatchWithError(r *http.Request) (bool, error) {
+ return m.Match(r), nil
+}
+
// CELLibrary produces options that expose this matcher for use in CEL
// expression matchers.
//