Use new gems methods.

This commit is contained in:
Marin Jankovski 2014-03-20 13:30:27 +01:00
parent 817f5ff6a3
commit 5f595be4b8
4 changed files with 3 additions and 6 deletions

View File

@ -1,4 +1,4 @@
:javascript
GitLab.GfmAutoComplete.dataSource = "#{autocomplete_sources_project_path(@project)}"
GitLab.GfmAutoComplete.Emoji.assetBase = "#{Gitlab.config.gitlab.relative_url_root + '/assets/emoji'}"
GitLab.GfmAutoComplete.Emoji.assetBase = "#{Gitlab.config.gitlab.relative_url_root + Emoji.asset_path}"
GitLab.GfmAutoComplete.setup();

View File

@ -23,7 +23,7 @@
%i.icon-thumbs-up
\+1
- if note.downvote?
%span.vote.downvote.label.label-error
%span.vote.downvote.label.label-danger
%i.icon-thumbs-down
\-1

View File

@ -1,3 +0,0 @@
# Workaround for https://github.com/github/gemoji/pull/18
require 'gemoji'
Gitlab::Application.config.assets.paths << Emoji.images_path

View File

@ -152,7 +152,7 @@ module Gitlab
#
# Returns boolean
def valid_emoji?(emoji)
Emoji.names.include? emoji
Emoji.find_by_name emoji
end
# Private: Dispatches to a dedicated processing method based on reference