aboutsummaryrefslogtreecommitdiffstats
path: root/app/helpers/application_helper.rb
diff options
context:
space:
mode:
authorSeb Bacon <seb.bacon@gmail.com>2012-06-14 14:01:11 +0100
committerSeb Bacon <seb.bacon@gmail.com>2012-06-14 14:01:11 +0100
commit3bd632b5930d155d21f1d9b015d711f3b03bb9f5 (patch)
treeec97c5348286f742aa279182dfb00d5e8a092433 /app/helpers/application_helper.rb
parentb30554dc4fcdeeb42d827ead474b1e135bc877e8 (diff)
Reformat function so it doesn't confuse gettext
Diffstat (limited to 'app/helpers/application_helper.rb')
-rw-r--r--app/helpers/application_helper.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb
index df016a249..cb6615199 100644
--- a/app/helpers/application_helper.rb
+++ b/app/helpers/application_helper.rb
@@ -127,7 +127,9 @@ module ApplicationHelper
end
def admin_date(date)
- "#{I18n.l(date, :format => "%e %B %Y %H:%M:%S")} (#{_('{{length_of_time}} ago', :length_of_time => time_ago_in_words(date))})"
+ ago_text = _('{{length_of_time}} ago', :length_of_time => time_ago_in_words(date))
+ exact_date = I18n.l(date, :format => "%e %B %Y %H:%M:%S")
+ return "#{exact_date} (#{ago_text})"
end
end