diff --git a/activesupport/lib/active_support/core_ext/string/output_safety.rb b/activesupport/lib/active_support/core_ext/string/output_safety.rb index 4089b02d4503d..f5622224d2d4f 100644 --- a/activesupport/lib/active_support/core_ext/string/output_safety.rb +++ b/activesupport/lib/active_support/core_ext/string/output_safety.rb @@ -126,9 +126,7 @@ def initialize_copy(other) end def clone_empty - new_safe_buffer = self[0, 0] - new_safe_buffer.instance_variable_set(:@dirty, @dirty) - new_safe_buffer + self[0, 0] end def concat(value)