summaryrefslogtreecommitdiff
path: root/app/models
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-01-18 00:09:18 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-01-18 00:09:18 +0000
commita1565a8243dd2cce29d0489d5ed40f9291d828d4 (patch)
treeed32d41117be241062ce5fd6a9576ed8a99fcffc /app/models
parent40254b9ace2a74a3c9f1cc51a1b1d5e3e78c1ae9 (diff)
downloadgitlab-ce-a1565a8243dd2cce29d0489d5ed40f9291d828d4.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models')
-rw-r--r--app/models/concerns/referable.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/concerns/referable.rb b/app/models/concerns/referable.rb
index 4a506146de3..3b0606aa425 100644
--- a/app/models/concerns/referable.rb
+++ b/app/models/concerns/referable.rb
@@ -74,7 +74,7 @@ module Referable
#{Regexp.escape(Gitlab.config.gitlab.url)}
\/#{Project.reference_pattern}
(?:\/\-)?
- \/#{Regexp.escape(route)}
+ \/#{route.is_a?(Regexp) ? route : Regexp.escape(route)}
\/#{pattern}
(?<path>
(\/[a-z0-9_=-]+)*