Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJack Davison <jack.davison@student.manchester.ac.uk>2016-06-23 22:02:11 +0300
committerJack Davison <jack.davison@student.manchester.ac.uk>2016-08-17 23:25:39 +0300
commit1fc17a8a43a87af89358953364872d565d38b8e8 (patch)
tree5021b7c5ede713f48a38758c3bb965427cf87e70 /app/helpers/issues_helper.rb
parent4fbbb8e76550fcb8103cc1bf5c8536cf598db829 (diff)
Switch to using to_sentence to construct tooltips
* Code in ruby now uses Array#to_sentence to construct award tooltips * Coffeescript uses a combination of regexes for the same result
Diffstat (limited to 'app/helpers/issues_helper.rb')
-rw-r--r--app/helpers/issues_helper.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/helpers/issues_helper.rb b/app/helpers/issues_helper.rb
index e8081d452c4..e5be8d2404a 100644
--- a/app/helpers/issues_helper.rb
+++ b/app/helpers/issues_helper.rb
@@ -122,9 +122,9 @@ module IssuesHelper
current_user_name = names.delete('me')
names = names.first(9).insert(0, current_user_name).compact
- names << "and #{awards.size - names.size} more." if awards.size > names.size
+ names << "#{awards.size - names.size} more." if awards.size > names.size
- names.join(', ')
+ names.to_sentence
end
def award_active_class(awards, current_user)