gitlab-org--gitlab-foss/app/helpers/award_emoji_helper.rb
Z.J. van de Weg e8dd0d54cb Fix tests for Snippets toggling awards
Also incorporate feedback
2016-09-19 19:53:09 +03:00

9 lines
246 B
Ruby

module AwardEmojiHelper
def toggle_award_url(awardable)
if @project
url_for([:toggle_award_emoji, @project.namespace.becomes(Namespace), @project, awardable])
else
url_for([:toggle_award_emoji, awardable])
end
end
end