diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-09-08 16:39:06 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-09-08 16:39:06 +0000 |
commit | 3c3d936f4d026336479c5ea0e953b8dcc823fbbd (patch) | |
tree | 078c7e080e747da18e2ddf3933d5d13297d1489e /actionpack/lib | |
parent | e6428abd23f8449900e174066a3acdd8ddcb7f03 (diff) | |
download | rails-3c3d936f4d026336479c5ea0e953b8dcc823fbbd.tar.gz rails-3c3d936f4d026336479c5ea0e953b8dcc823fbbd.tar.bz2 rails-3c3d936f4d026336479c5ea0e953b8dcc823fbbd.zip |
Fixed all AssetHelper methods to work with relative paths, such that javascript_include_tag('stdlib/standard') will look in /javascripts/stdlib/standard instead of '/stdlib/standard/' #1963
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2156 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/action_view/helpers/asset_tag_helper.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_view/helpers/asset_tag_helper.rb b/actionpack/lib/action_view/helpers/asset_tag_helper.rb index cd56592300..fea7abe3f9 100644 --- a/actionpack/lib/action_view/helpers/asset_tag_helper.rb +++ b/actionpack/lib/action_view/helpers/asset_tag_helper.rb @@ -119,7 +119,7 @@ module ActionView private def compute_public_path(source, dir, ext) - source = "/#{dir}/#{source}" unless source.include?("/") + source = "/#{dir}/#{source}" unless source.first == "/" || source.include?(":") source = "#{source}.#{ext}" unless source.include?(".") source = "#{@request.relative_url_root}#{source}" unless %r{^[-a-z]+://} =~ source ActionController::Base.asset_host + source |