Commit c7479e4def461cd619b5556ab4d0a0f209712740
1 parent
dd172119
Exists in
master
and in
29 other branches
rails3: fix the use of helper_for_article with url_for
Showing
1 changed file
with
1 additions
and
0 deletions
Show diff stats
app/helpers/application_helper.rb
@@ -890,6 +890,7 @@ module ApplicationHelper | @@ -890,6 +890,7 @@ module ApplicationHelper | ||
890 | article_helper = ActionView::Base.new | 890 | article_helper = ActionView::Base.new |
891 | article_helper.controller = controller | 891 | article_helper.controller = controller |
892 | article_helper.extend ArticleHelper | 892 | article_helper.extend ArticleHelper |
893 | + article_helper.extend Rails.application.routes.url_helpers | ||
893 | begin | 894 | begin |
894 | class_name = article.class.name + 'Helper' | 895 | class_name = article.class.name + 'Helper' |
895 | klass = class_name.constantize | 896 | klass = class_name.constantize |