use middleware.Path for base path comparison

This commit is contained in:
Abiola Ibrahim 2015-05-16 16:57:57 +01:00
parent 7ae9e3a262
commit c382c885e4

View file

@ -109,7 +109,7 @@ func (r *RegexpRule) Rewrite(req *http.Request) bool {
rPath := req.URL.Path
// validate base
if !strings.HasPrefix(rPath, r.Base) {
if !middleware.Path(rPath).Matches(r.Base) {
return false
}