diff options
author | Sean McGivern <sean@mcgivern.me.uk> | 2017-04-05 14:31:18 +0000 |
---|---|---|
committer | Sean McGivern <sean@mcgivern.me.uk> | 2017-04-05 14:31:18 +0000 |
commit | 32e9e24a89679427804cb15e1b76462bd67f628a (patch) | |
tree | c4045867356287fbca428ae78281d56271f95737 | |
parent | 7196adaaa4ce5aa259d285dbca6aa98f4deb046b (diff) | |
parent | 63a6453c0136a6244b0351ab6350dcee62a45cf9 (diff) | |
download | gitlab-ce-32e9e24a89679427804cb15e1b76462bd67f628a.tar.gz |
Merge branch 'wildcard-routes-in-etag-middleware' into 'master'
Use NamespaceValidator::WILDCARD_ROUTES in ETag caching middleware
See merge request !10478
-rw-r--r-- | lib/gitlab/etag_caching/middleware.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/etag_caching/middleware.rb b/lib/gitlab/etag_caching/middleware.rb index 9c98f0d1a30..ab8dfc67880 100644 --- a/lib/gitlab/etag_caching/middleware.rb +++ b/lib/gitlab/etag_caching/middleware.rb @@ -1,7 +1,7 @@ module Gitlab module EtagCaching class Middleware - RESERVED_WORDS = ProjectPathValidator::RESERVED.map { |word| "/#{word}/" }.join('|') + RESERVED_WORDS = NamespaceValidator::WILDCARD_ROUTES.map { |word| "/#{word}/" }.join('|') ROUTE_REGEXP = Regexp.union( %r(^(?!.*(#{RESERVED_WORDS})).*/noteable/issue/\d+/notes\z) ) |