From e7d36df945792b292732e25e879a90577050a6c1 Mon Sep 17 00:00:00 2001 From: Azul Date: Tue, 15 Jan 2013 11:06:46 +0100 Subject: minor: put emails in unstyled ul and simplify Just found out that render(@collection) returns nil for emtpy collections. So that is usefull for putting messages about the emtpy collection in an or clause. --- users/app/views/users/show.html.haml | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'users/app') diff --git a/users/app/views/users/show.html.haml b/users/app/views/users/show.html.haml index 2b59c66..d8b51e9 100644 --- a/users/app/views/users/show.html.haml +++ b/users/app/views/users/show.html.haml @@ -12,16 +12,12 @@ %dt =t :email_aliases %dd - - aliases = @user.email_aliases - - if aliases.empty? - none set - - else - .pull-left - = render aliases + %ul.pull-left.unstyled + = render(@user.email_aliases) || t(:none_set) .clearfix %dt =t :most_recently_updated_tickets %dd %table %tbody - = render @user.most_recent_tickets \ No newline at end of file + = render @user.most_recent_tickets -- cgit v1.2.3