2016-09-04 04:51:12 -04:00
|
|
|
module AwardEmojiHelper
|
|
|
|
def toggle_award_url(awardable)
|
2016-09-07 08:48:43 -04:00
|
|
|
if @project
|
|
|
|
url_for([:toggle_award_emoji, @project.namespace.becomes(Namespace), @project, awardable])
|
2016-09-04 04:51:12 -04:00
|
|
|
else
|
2016-09-07 08:48:43 -04:00
|
|
|
url_for([:toggle_award_emoji, awardable])
|
2016-09-04 04:51:12 -04:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|