Skip to content
Browse files

Remove slash from favicon_link_tag method attribute

  • Loading branch information...
1 parent 40c287c commit a5976ccc371382ad7fb9645252c19c4e437d353c @lucascaton lucascaton committed
View
2 actionpack/CHANGELOG.md
@@ -26,6 +26,8 @@
This is a behavior change, previously the hidden tag had a value of the disabled checkbox.
*Tadas Tamosauskas*
+* `favicon_link_tag` helper will now use the favicon in app/assets by default. *Lucas Caton*
+
## Rails 3.2.0 (January 20, 2012) ##
* Add `config.action_dispatch.default_charset` to configure default charset for ActionDispatch::Response. *Carlos Antonio da Silva*
View
4 actionpack/lib/action_view/helpers/asset_tag_helper.rb
@@ -234,7 +234,7 @@ def auto_discovery_link_tag(type = :rss, url_options = {}, tag_options = {})
#
# generates
#
- # <link href="/favicon.ico" rel="shortcut icon" type="image/vnd.microsoft.icon" />
+ # <link href="/assets/favicon.ico" rel="shortcut icon" type="image/vnd.microsoft.icon" />
#
# You may specify a different file in the first argument:
#
@@ -252,7 +252,7 @@ def auto_discovery_link_tag(type = :rss, url_options = {}, tag_options = {})
#
# <%= favicon_link_tag 'mb-icon.png', :rel => 'apple-touch-icon', :type => 'image/png' %>
#
- def favicon_link_tag(source='/favicon.ico', options={})
+ def favicon_link_tag(source='favicon.ico', options={})
tag('link', {
:rel => 'shortcut icon',
:type => 'image/vnd.microsoft.icon',
View
2 actionpack/test/template/asset_tag_helper_test.rb
@@ -168,7 +168,7 @@ def teardown
}
FaviconLinkToTag = {
- %(favicon_link_tag) => %(<link href="/favicon.ico" rel="shortcut icon" type="image/vnd.microsoft.icon" />),
+ %(favicon_link_tag) => %(<link href="/images/favicon.ico" rel="shortcut icon" type="image/vnd.microsoft.icon" />),
%(favicon_link_tag 'favicon.ico') => %(<link href="/images/favicon.ico" rel="shortcut icon" type="image/vnd.microsoft.icon" />),
%(favicon_link_tag 'favicon.ico', :rel => 'foo') => %(<link href="/images/favicon.ico" rel="foo" type="image/vnd.microsoft.icon" />),
%(favicon_link_tag 'favicon.ico', :rel => 'foo', :type => 'bar') => %(<link href="/images/favicon.ico" rel="foo" type="bar" />),

0 comments on commit a5976cc

Please sign in to comment.
Something went wrong with that request. Please try again.