From ef4b8c237a3e2d0bc59f06c5696004dca27efe0a Mon Sep 17 00:00:00 2001 From: Jamis Buck Date: Thu, 30 Mar 2006 15:15:26 +0000 Subject: Make asset timestamping safe to use on assets that don't exist git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4103 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- actionpack/lib/action_view/helpers/asset_tag_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'actionpack') diff --git a/actionpack/lib/action_view/helpers/asset_tag_helper.rb b/actionpack/lib/action_view/helpers/asset_tag_helper.rb index 21708a37ef..2d9d7556eb 100644 --- a/actionpack/lib/action_view/helpers/asset_tag_helper.rb +++ b/actionpack/lib/action_view/helpers/asset_tag_helper.rb @@ -160,7 +160,7 @@ module ActionView def rails_asset_id(source) ENV["RAILS_ASSET_ID"] || - File.stat(RAILS_ROOT + "/public/#{source}").mtime.to_i.to_s + File.mtime("#{RAILS_ROOT}/public/#{source}").to_i.to_s rescue "" end end end -- cgit v1.2.3