diff options
author | Rafael Mendonça França <rafael.franca@plataformatec.com.br> | 2012-01-04 14:28:01 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafael.franca@plataformatec.com.br> | 2012-01-04 14:28:01 -0300 |
commit | bdc49dcb4ee2af23599965e98fec1bfe21561c23 (patch) | |
tree | 065dff6c3223adf410adbcc778198d494dc85458 | |
parent | b65bdb1527dbf42d94e5722f6764cebac73d103c (diff) | |
download | rails-bdc49dcb4ee2af23599965e98fec1bfe21561c23.tar.gz rails-bdc49dcb4ee2af23599965e98fec1bfe21561c23.tar.bz2 rails-bdc49dcb4ee2af23599965e98fec1bfe21561c23.zip |
No need to override to_yaml and yaml_initialize methods in ActiveRecord::Core
-rw-r--r-- | activerecord/lib/active_record/core.rb | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/activerecord/lib/active_record/core.rb b/activerecord/lib/active_record/core.rb index ee7ff7a2d7..0755379a74 100644 --- a/activerecord/lib/active_record/core.rb +++ b/activerecord/lib/active_record/core.rb @@ -317,26 +317,6 @@ module ActiveRecord "#<#{self.class} #{inspection}>" end - # Hackery to accomodate Syck. Remove for 4.0. - def to_yaml(opts = {}) #:nodoc: - if !YAML::ENGINE.syck? - super - else - coder = {} - encode_with(coder) - YAML.quick_emit(self, opts) do |out| - out.map(taguri, to_yaml_style) do |map| - coder.each { |k, v| map.add(k, v) } - end - end - end - end - - # Hackery to accomodate Syck. Remove for 4.0. - def yaml_initialize(tag, coder) #:nodoc: - init_with(coder) - end - private # Under Ruby 1.9, Array#flatten will call #to_ary (recursively) on each of the elements |