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
Jérome Perrin
gitlab-ce
Commits
78be7055
Commit
78be7055
authored
Nov 21, 2015
by
Robert Speicher
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'award_fix' into 'master'
Award Emoji: fix for merge requests Closes #3597 See merge request !1865
parents
c502695f
fbac9e10
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
2 deletions
+5
-2
app/controllers/projects/notes_controller.rb
app/controllers/projects/notes_controller.rb
+5
-2
No files found.
app/controllers/projects/notes_controller.rb
View file @
78be7055
...
@@ -59,8 +59,11 @@ class Projects::NotesController < Projects::ApplicationController
...
@@ -59,8 +59,11 @@ class Projects::NotesController < Projects::ApplicationController
end
end
def
award_toggle
def
award_toggle
noteable
=
note_params
[
:noteable_type
]
==
"issue"
?
Issue
:
MergeRequest
noteable
=
if
note_params
[
:noteable_type
]
==
"issue"
noteable
=
noteable
.
find_by!
(
id:
note_params
[
:noteable_id
],
project:
project
)
project
.
issues
.
find
(
note_params
[
:noteable_id
])
else
project
.
merge_requests
.
find
(
note_params
[
:noteable_id
])
end
data
=
{
data
=
{
author:
current_user
,
author:
current_user
,
...
...
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