diff options
Diffstat (limited to 'railties')
-rw-r--r-- | railties/guides/rails_guides/generator.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/railties/guides/rails_guides/generator.rb b/railties/guides/rails_guides/generator.rb index 4682ead66e..6f6d3bda80 100644 --- a/railties/guides/rails_guides/generator.rb +++ b/railties/guides/rails_guides/generator.rb @@ -137,7 +137,8 @@ module RailsGuides if guide =~ /\.html\.erb$/ # Generate the special pages like the home. - result = view.render(:layout => 'layout', :file => guide) + # Passing a template handler in the template name is deprecated. So pass the file name without the extension. + result = view.render(:layout => 'layout', :file => $`) else body = File.read(File.join(source_dir, guide)) body = set_header_section(body, view) |