From afde19052e0b9a37ec531d6c5c32b59209a80fcc Mon Sep 17 00:00:00 2001 From: Harry Bomrah Date: Thu, 25 Jun 2015 15:27:29 +0800 Subject: [PATCH] added default hash for links --- app/views/pages/_form_link.html.erb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/views/pages/_form_link.html.erb b/app/views/pages/_form_link.html.erb index 471f793..0d61764 100644 --- a/app/views/pages/_form_link.html.erb +++ b/app/views/pages/_form_link.html.erb @@ -40,9 +40,11 @@ else url = @page.external_url_translations[locale] end + else + url = "#" end %> - <%= n.text_field locale, class:"input-xlarge change", :value=>url rescue nil %> + <%= n.text_field locale, class:"input-xlarge change", :value=>url rescue "#" %> <% end %> <% end %>