From 9d3f221f1a14de4895f23ee84499992d33b1ce7a Mon Sep 17 00:00:00 2001 From: Florian Staudacher Date: Thu, 29 Mar 2012 16:28:53 +0200 Subject: [PATCH] fix the js error when not logged in and on root/landing page, app is undefined --- app/helpers/layout_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/helpers/layout_helper.rb b/app/helpers/layout_helper.rb index 3eff5c2ba..1fc93ea96 100644 --- a/app/helpers/layout_helper.rb +++ b/app/helpers/layout_helper.rb @@ -21,7 +21,7 @@ module LayoutHelper path = ENV['ASSET_HOST'].to_s + '/assets/' content_tag(:script) do <<-JS.html_safe - app.baseImageUrl("#{path}") + if(window.app) app.baseImageUrl("#{path}") JS end end