aboutsummaryrefslogtreecommitdiffstats
path: root/activeresource/lib/active_resource/custom_methods.rb
diff options
context:
space:
mode:
authorGonçalo Silva <goncalossilva@gmail.com>2011-03-24 17:21:17 +0000
committerGonçalo Silva <goncalossilva@gmail.com>2011-03-24 17:21:17 +0000
commit9887f238871bb2dd73de6ce8855615bcc5d8d079 (patch)
tree74fa9ff9524a51701cfa23f708b3f777c65b7fe5 /activeresource/lib/active_resource/custom_methods.rb
parentaff821508a16245ebc03510ba29c70379718dfb7 (diff)
parent5214e73850916de3c9127d35a4ecee0424d364a3 (diff)
downloadrails-9887f238871bb2dd73de6ce8855615bcc5d8d079.tar.gz
rails-9887f238871bb2dd73de6ce8855615bcc5d8d079.tar.bz2
rails-9887f238871bb2dd73de6ce8855615bcc5d8d079.zip
Merge branch 'master' of https://github.com/rails/rails
Diffstat (limited to 'activeresource/lib/active_resource/custom_methods.rb')
-rw-r--r--activeresource/lib/active_resource/custom_methods.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/activeresource/lib/active_resource/custom_methods.rb b/activeresource/lib/active_resource/custom_methods.rb
index dd3e35dfc7..9879f8cded 100644
--- a/activeresource/lib/active_resource/custom_methods.rb
+++ b/activeresource/lib/active_resource/custom_methods.rb
@@ -54,7 +54,7 @@ module ActiveResource
#
# Person.find(:all, :from => :active)
def get(custom_method_name, options = {})
- connection.get(custom_method_collection_url(custom_method_name, options), headers)
+ format.decode(connection.get(custom_method_collection_url(custom_method_name, options), headers).body)
end
def post(custom_method_name, options = {}, body = '')
@@ -85,7 +85,7 @@ module ActiveResource
module InstanceMethods
def get(method_name, options = {})
- connection.get(custom_method_element_url(method_name, options), self.class.headers)
+ self.class.format.decode(connection.get(custom_method_element_url(method_name, options), self.class.headers).body)
end
def post(method_name, options = {}, body = nil)