Actions
Patch #40087
closedRewrite ApplicationHelper#favicon_url method using image_url
Status:
Closed
Priority:
Normal
Assignee:
Category:
Code cleanup/refactoring
Target version:
Start date:
Due date:
% Done:
0%
Estimated time:
Description
This change deals with the comment "TODO: use #image_url introduced in Rails4" in ApplicationHelper#favicon_url.
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb
index a82163b76..4d87f6075 100644
--- a/app/helpers/application_helper.rb
+++ b/app/helpers/application_helper.rb
@@ -1759,10 +1759,7 @@ module ApplicationHelper
# Returns the full URL to the favicon
def favicon_url
- # TODO: use #image_url introduced in Rails4
- path = favicon_path
- base = url_for(:controller => 'welcome', :action => 'index', :only_path => false)
- base.sub(%r{/+$}, '') + '/' + path.sub(%r{^/+}, '')
+ image_url(favicon_path)
end
def robot_exclusion_tag
Updated by Marius BĂLTEANU 11 months ago
- Status changed from New to Closed
- Assignee set to Marius BĂLTEANU
Committed, thanks!
Actions