aboutsummaryrefslogtreecommitdiffstats
path: root/railties/guides/rails_guides
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2010-02-02 01:04:35 +0100
committerXavier Noria <fxn@hashref.com>2010-02-02 01:04:35 +0100
commit9b5dae7af5757769c1e69d74a59ff036adc1f30f (patch)
tree7990622f5995c04911dfc90df044b762e293746e /railties/guides/rails_guides
parentfdcf4d6c5191b25ee3b6c357dafaf17156eb09d3 (diff)
downloadrails-9b5dae7af5757769c1e69d74a59ff036adc1f30f.tar.gz
rails-9b5dae7af5757769c1e69d74a59ff036adc1f30f.tar.bz2
rails-9b5dae7af5757769c1e69d74a59ff036adc1f30f.zip
update html_safe calls in guides generation
Diffstat (limited to 'railties/guides/rails_guides')
-rw-r--r--railties/guides/rails_guides/generator.rb14
1 files changed, 4 insertions, 10 deletions
diff --git a/railties/guides/rails_guides/generator.rb b/railties/guides/rails_guides/generator.rb
index bd25111405..6a41bde9f6 100644
--- a/railties/guides/rails_guides/generator.rb
+++ b/railties/guides/rails_guides/generator.rb
@@ -1,11 +1,5 @@
require 'set'
-class String
- def html_safe!
- self
- end unless "post 9415935902f120a9bac0bfce7129725a0db38ed3".respond_to?(:html_safe!)
-end
-
module RailsGuides
class Generator
attr_reader :output, :view_path, :view, :guides_dir
@@ -61,7 +55,7 @@ module RailsGuides
body = set_header_section(body, @view)
body = set_index(body, @view)
- result = view.render(:layout => 'layout', :text => textile(body).html_safe!)
+ result = view.render(:layout => 'layout', :text => textile(body).html_safe)
f.write result
warn_about_broken_links(result) if ENV.key?("WARN_BROKEN_LINKS")
end
@@ -77,8 +71,8 @@ module RailsGuides
header = textile(header)
- view.content_for(:page_title) { page_title.html_safe! }
- view.content_for(:header_section) { header.html_safe! }
+ view.content_for(:page_title) { page_title.html_safe }
+ view.content_for(:header_section) { header.html_safe }
new_body
end
@@ -109,7 +103,7 @@ module RailsGuides
index << '</ol>'
index << '</div>'
- view.content_for(:index_section) { index.html_safe! }
+ view.content_for(:index_section) { index.html_safe }
i.result
end