aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack
diff options
context:
space:
mode:
authorJosé Valim <jose.valim@gmail.com>2010-08-29 21:15:00 -0300
committerJosé Valim <jose.valim@gmail.com>2010-08-29 21:15:00 -0300
commit3c8e1f99b9613cca4813e2a1b062d58ec4b2627b (patch)
tree5c7c931aa9f76ada944536996b931154583c584f /actionpack
parentba52748d05da4f95a8f371d628af97b76644bdd3 (diff)
downloadrails-3c8e1f99b9613cca4813e2a1b062d58ec4b2627b.tar.gz
rails-3c8e1f99b9613cca4813e2a1b062d58ec4b2627b.tar.bz2
rails-3c8e1f99b9613cca4813e2a1b062d58ec4b2627b.zip
Remove NonConcattingString.
Diffstat (limited to 'actionpack')
-rw-r--r--actionpack/lib/action_view/base.rb3
-rw-r--r--actionpack/lib/action_view/helpers/capture_helper.rb2
-rw-r--r--actionpack/test/template/capture_helper_test.rb2
3 files changed, 1 insertions, 6 deletions
diff --git a/actionpack/lib/action_view/base.rb b/actionpack/lib/action_view/base.rb
index 20a2e7c1f0..ff25c36fcd 100644
--- a/actionpack/lib/action_view/base.rb
+++ b/actionpack/lib/action_view/base.rb
@@ -6,9 +6,6 @@ require 'active_support/ordered_options'
require 'action_view/log_subscriber'
module ActionView #:nodoc:
- class NonConcattingString < ActiveSupport::SafeBuffer
- end
-
# = Action View Base
#
# Action View templates can be written in three ways. If the template file has a <tt>.erb</tt> (or <tt>.rhtml</tt>) extension then it uses a mixture of ERb
diff --git a/actionpack/lib/action_view/helpers/capture_helper.rb b/actionpack/lib/action_view/helpers/capture_helper.rb
index 52e71a4c3a..0401e6a09b 100644
--- a/actionpack/lib/action_view/helpers/capture_helper.rb
+++ b/actionpack/lib/action_view/helpers/capture_helper.rb
@@ -38,7 +38,7 @@ module ActionView
value = nil
buffer = with_output_buffer { value = yield(*args) }
if string = buffer.presence || value and string.is_a?(String)
- NonConcattingString.new(string)
+ string
end
end
diff --git a/actionpack/test/template/capture_helper_test.rb b/actionpack/test/template/capture_helper_test.rb
index f7c42c7f22..8f81076299 100644
--- a/actionpack/test/template/capture_helper_test.rb
+++ b/actionpack/test/template/capture_helper_test.rb
@@ -15,7 +15,6 @@ class CaptureHelperTest < ActionView::TestCase
end
assert_nil @av.output_buffer
assert_equal 'foobar', string
- assert_kind_of ActionView::NonConcattingString, string
end
def test_capture_captures_the_value_returned_by_the_block_if_the_temporary_buffer_is_blank
@@ -23,7 +22,6 @@ class CaptureHelperTest < ActionView::TestCase
a + b
end
assert_equal 'foobar', string
- assert_kind_of ActionView::NonConcattingString, string
end
def test_capture_returns_nil_if_the_returned_value_is_not_a_string