summaryrefslogtreecommitdiff
path: root/config/routes.rb
diff options
context:
space:
mode:
authorStan Hu <stanhu@gmail.com>2015-10-12 21:43:24 -0700
committerStan Hu <stanhu@gmail.com>2015-10-12 22:24:19 -0700
commitd02d02c672bcac0d2ef46204d132645bc69827a8 (patch)
treec0052740b3617bcba60174238f93f1ea108f6709 /config/routes.rb
parente12b6f30efef3f607cacc5da51f8c49c3be4643a (diff)
downloadgitlab-ce-d02d02c672bcac0d2ef46204d132645bc69827a8.tar.gz
Fix error preventing displaying of commit data for a directory with a leading dot
Closes https://github.com/gitlabhq/gitlabhq/issues/8763
Diffstat (limited to 'config/routes.rb')
-rw-r--r--config/routes.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/config/routes.rb b/config/routes.rb
index 8e6fbf6340c..893ab59c327 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -543,8 +543,10 @@ Gitlab::Application.routes.draw do
member do
# tree viewer logs
get 'logs_tree', constraints: { id: Gitlab::Regex.git_reference_regex }
+ # Directories with leading dots erroneously get rejected if git
+ # ref regex used in constraints. Regex verification now done in controller.
get 'logs_tree/*path' => 'refs#logs_tree', as: :logs_file, constraints: {
- id: Gitlab::Regex.git_reference_regex,
+ id: /.*/,
path: /.*/
}
end