Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
834b23a7
Commit
834b23a7
authored
Jun 13, 2014
by
Jacob Vosmaer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix JIRA issue reference bug
parent
f1d32896
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
1 deletion
+17
-1
CHANGELOG-EE
CHANGELOG-EE
+1
-0
app/models/concerns/mentionable.rb
app/models/concerns/mentionable.rb
+2
-1
spec/models/concerns/mentionable_spec.rb
spec/models/concerns/mentionable_spec.rb
+14
-0
No files found.
CHANGELOG-EE
View file @
834b23a7
v 7.0.0
- Fix bug in JIRA Issue closing triggered by commit messages
- Fix JIRA issue reference bug
v 6.9.3
- Fix check CI status only when CI service is enabled(Daniel Aquino)
...
...
app/models/concerns/mentionable.rb
View file @
834b23a7
...
...
@@ -64,7 +64,8 @@ module Mentionable
return
[]
if
text
.
blank?
ext
=
Gitlab
::
ReferenceExtractor
.
new
ext
.
analyze
(
text
)
(
ext
.
issues_for
(
p
)
+
ext
.
merge_requests_for
(
p
)
+
ext
.
commits_for
(
p
)).
uniq
-
[
local_reference
]
issues
=
ext
.
issues_for
(
p
).
select
{
|
issue
|
issue
.
is_a?
(
Issue
)
}
(
issues
+
ext
.
merge_requests_for
(
p
)
+
ext
.
commits_for
(
p
)).
uniq
-
[
local_reference
]
end
# Create a cross-reference Note for each GFM reference to another Mentionable found in +mentionable_text+.
...
...
spec/models/concerns/mentionable_spec.rb
0 → 100644
View file @
834b23a7
require
'spec_helper'
describe
Mentionable
do
include
Mentionable
describe
:references
do
let
(
:project
)
{
create
(
:project
)
}
it
'excludes JIRA references'
do
project
.
stub
(
jira_tracker?:
true
)
references
(
project
,
'JIRA-123'
).
should
be_empty
end
end
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment