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
0
Merge Requests
0
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
Boxiang Sun
gitlab-ce
Commits
24566954
Commit
24566954
authored
Apr 21, 2015
by
Douwe Maan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix errors.
parent
4dd2f881
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
3 deletions
+2
-3
app/models/note.rb
app/models/note.rb
+2
-2
lib/gitlab/push_data_builder.rb
lib/gitlab/push_data_builder.rb
+0
-1
No files found.
app/models/note.rb
View file @
24566954
...
@@ -272,7 +272,7 @@ class Note < ActiveRecord::Base
...
@@ -272,7 +272,7 @@ class Note < ActiveRecord::Base
# cross-project references. For same-project references, return the
# cross-project references. For same-project references, return the
# unmodified GFM reference.
# unmodified GFM reference.
def
mentioner_gfm_ref
(
noteable
,
mentioner
,
mentioner_project
=
mentioner
.
project
)
def
mentioner_gfm_ref
(
noteable
,
mentioner
,
mentioner_project
=
mentioner
.
project
)
if
mentioner
.
is_a?
(
Commit
)
&&
project
.
nil?
if
mentioner
.
is_a?
(
Commit
)
&&
mentioner_
project
.
nil?
return
mentioner
.
gfm_reference
.
sub
(
'commit '
,
'commit %'
)
return
mentioner
.
gfm_reference
.
sub
(
'commit '
,
'commit %'
)
end
end
...
@@ -283,7 +283,7 @@ class Note < ActiveRecord::Base
...
@@ -283,7 +283,7 @@ class Note < ActiveRecord::Base
# projects are not the same, add the mentioning project's path to the
# projects are not the same, add the mentioning project's path to the
# returned value.
# returned value.
def
full_gfm_reference
(
mentioning_project
,
noteable_project
,
mentioner
)
def
full_gfm_reference
(
mentioning_project
,
noteable_project
,
mentioner
)
if
mentioning_project
.
id
==
noteable_project
if
mentioning_project
==
noteable_project
mentioner
.
gfm_reference
mentioner
.
gfm_reference
else
else
if
mentioner
.
is_a?
(
Commit
)
if
mentioner
.
is_a?
(
Commit
)
...
...
lib/gitlab/push_data_builder.rb
View file @
24566954
...
@@ -31,7 +31,6 @@ module Gitlab
...
@@ -31,7 +31,6 @@ module Gitlab
# For performance purposes maximum 20 latest commits
# For performance purposes maximum 20 latest commits
# will be passed as post receive hook data.
# will be passed as post receive hook data.
commit_attrs
=
commits_limited
.
map
(
&
:hook_attrs
)
commit_attrs
=
commits_limited
.
map
(
&
:hook_attrs
)
end
type
=
Gitlab
::
Git
.
tag_ref?
(
ref
)
?
"tag_push"
:
"push"
type
=
Gitlab
::
Git
.
tag_ref?
(
ref
)
?
"tag_push"
:
"push"
# Hash to be passed as post_receive_data
# Hash to be passed as post_receive_data
...
...
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