Skip to content

Commit

Permalink
No need to override the to_yaml method in ActiveSupporte::SafeBuffer
Browse files Browse the repository at this point in the history
  • Loading branch information
Rafael Mendonça França committed Jan 4, 2012
1 parent d8ed247 commit ae7dcb4
Showing 1 changed file with 0 additions and 5 deletions.
Expand Up @@ -136,11 +136,6 @@ def encode_with(coder)
coder.represent_scalar nil, to_str coder.represent_scalar nil, to_str
end end


def to_yaml(*args)
return super() if !YAML::ENGINE.syck?
to_str.to_yaml(*args)
end

UNSAFE_STRING_METHODS.each do |unsafe_method| UNSAFE_STRING_METHODS.each do |unsafe_method|
if 'String'.respond_to?(unsafe_method) if 'String'.respond_to?(unsafe_method)
class_eval <<-EOT, __FILE__, __LINE__ + 1 class_eval <<-EOT, __FILE__, __LINE__ + 1
Expand Down

0 comments on commit ae7dcb4

Please sign in to comment.