]> git.openstreetmap.org Git - rails.git/blobdiff - app/views/message/_message_count.html.erb
Use a current_user helper for accessing the logged in user in all views.
[rails.git] / app / views / message / _message_count.html.erb
index 27b0aa644f0f58cf6e7446b73ef929737164e618..3a995c17144bb37e389a8de93c49e0d77dbbc83b 100644 (file)
@@ -1 +1,8 @@
-<p id="inbox-count"><%= t'message.inbox.you_have', :new_count => @user.new_messages.size, :old_count => (@user.messages.size -  @user.new_messages.size) %></p> 
+<p id="inbox-count">
+<%= t "message.inbox.messages",
+      :new_messages => t("message.inbox.new_messages",
+                         :count => current_user.new_messages.size),
+      :old_messages => t("message.inbox.old_messages",
+                         :count => current_user.messages.size - current_user.new_messages.size)
+%>
+</p>