From: Jigar Gosar Date: 2008-02-21T23:56:34+09:00 Subject: Code Reduction I am using ERB templates in my code. It seems too big, can't get my head around on how to reduce it. I am sure this can be made smaller. My problem is that if there ain't any flash messages than the contained HTML shouldn't be rendered at all. <% if flash[:notice] %>
<%= flash[:notice] %>
<% end %> <% if flash[:error] %>
<%= flash[:error] %>
<% end %> thanks. -- Posted via http://www.ruby-forum.com/.