From d4457dc32b4d5dc9fde6c852f55a0d43ee021282 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Valim?= Date: Fri, 30 Sep 2011 14:20:41 +0200 Subject: Provide read_attribute_for_serialization as the API to serialize attributes. --- activeresource/lib/active_resource/base.rb | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'activeresource') diff --git a/activeresource/lib/active_resource/base.rb b/activeresource/lib/active_resource/base.rb index 1ffd83b91d..03c4cc5b9e 100644 --- a/activeresource/lib/active_resource/base.rb +++ b/activeresource/lib/active_resource/base.rb @@ -1384,6 +1384,10 @@ module ActiveResource private + def read_attribute_for_serialization(n) + attributes[n] + end + # Determine whether the response is allowed to have a body per HTTP 1.1 spec section 4.4.1 def response_code_allows_body?(c) !((100..199).include?(c) || [204,304].include?(c)) -- cgit v1.2.3