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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
eb928137
Commit
eb928137
authored
Oct 10, 2012
by
Riyad Preukschas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move emoji auto-complete helper to ApplicationHelper
parent
682f62fd
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
16 deletions
+6
-16
app/helpers/application_helper.rb
app/helpers/application_helper.rb
+6
-0
app/helpers/notes_helper.rb
app/helpers/notes_helper.rb
+0
-6
spec/helpers/notes_helper_spec.rb
spec/helpers/notes_helper_spec.rb
+0
-10
No files found.
app/helpers/application_helper.rb
View file @
eb928137
...
...
@@ -98,6 +98,12 @@ module ApplicationHelper
[
projects
,
default_nav
,
project_nav
].
flatten
.
to_json
end
def
emoji_autocomplete_source
# should be an array of strings
# so to_s can be called, because it is sufficient and to_json is too slow
Emoji
::
NAMES
.
to_s
end
def
ldap_enable?
Devise
.
omniauth_providers
.
include?
(
:ldap
)
end
...
...
app/helpers/notes_helper.rb
View file @
eb928137
...
...
@@ -14,10 +14,4 @@ module NotesHelper
"vote downvote"
end
end
def
emoji_for_completion
# should be an array of strings
# so to_s can be called, because it is sufficient and to_json is too slow
Emoji
::
NAMES
end
end
spec/helpers/notes_helper_spec.rb
deleted
100644 → 0
View file @
682f62fd
require
'spec_helper'
describe
NotesHelper
do
describe
"#emoji_for_completion"
do
it
"should be an Array of Strings"
do
emoji_for_completion
.
should
be_a
(
Array
)
emoji_for_completion
.
each
{
|
emoji
|
emoji
.
should
be_a
(
String
)
}
end
end
end
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