diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-18 15:09:15 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-18 15:09:15 +0300 |
commit | 0637ba1e6e9024f35b2cbf561d9002ec17350bb3 (patch) | |
tree | 960cebf0e892710c1b40f25e249d04aaf8f9b868 /lib/gitlab/regex.rb | |
parent | 4720b569f0fcbb47e9f1a60e95172ae63b6f065a (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/gitlab/regex.rb')
-rw-r--r-- | lib/gitlab/regex.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/gitlab/regex.rb b/lib/gitlab/regex.rb index fd6e24a96d8..38281fb1c91 100644 --- a/lib/gitlab/regex.rb +++ b/lib/gitlab/regex.rb @@ -112,7 +112,7 @@ module Gitlab # Based on Jira's project key format # https://confluence.atlassian.com/adminjiraserver073/changing-the-project-key-format-861253229.html def jira_issue_key_regex - @jira_issue_key_regex ||= /[A-Z][A-Z_0-9]+-\d+/ + @jira_issue_key_regex ||= /[A-Z][A-Z_0-9]+-\d+\b/ end def jira_transition_id_regex @@ -144,6 +144,10 @@ module Gitlab def utc_date_regex @utc_date_regex ||= /\A[0-9]{4}-[0-9]{2}-[0-9]{2}\z/.freeze end + + def issue + @issue ||= /(?<issue>\d+\b)/ + end end end |