From a9a3fe7f94ebf14a5e70a642a596010572544424 Mon Sep 17 00:00:00 2001 From: radhika Date: Thu, 2 Oct 2014 08:32:05 -0400 Subject: [PATCH] 4036: improve rails flash message display to check if the message is an error. --- .../app/views/application/_title_and_buttons.html.erb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apps/workbench/app/views/application/_title_and_buttons.html.erb b/apps/workbench/app/views/application/_title_and_buttons.html.erb index 817549a2fe..4838f2dfbb 100644 --- a/apps/workbench/app/views/application/_title_and_buttons.html.erb +++ b/apps/workbench/app/views/application/_title_and_buttons.html.erb @@ -51,10 +51,12 @@ <% flash_msg = '' + flash_msg_is_error = false flash.each do |msg| + flash_msg_is_error ||= (msg[0]=='error') flash_msg += ('

' + msg[1] + '

') end if flash_msg != '' %> - + <% end %> -- 2.30.2