diff options
Diffstat (limited to 'activeresource/lib/active_resource/base.rb')
-rw-r--r-- | activeresource/lib/active_resource/base.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/activeresource/lib/active_resource/base.rb b/activeresource/lib/active_resource/base.rb index 4192fab525..94418fb559 100644 --- a/activeresource/lib/active_resource/base.rb +++ b/activeresource/lib/active_resource/base.rb @@ -746,8 +746,8 @@ module ActiveResource # # => true # def ==(other) - other.equal?(self) || (other.instance_of?(self.class) && !other.new? && other.id == id) - end + other.equal?(self) || (other.instance_of?(self.class) && other.id == id && other.prefix_options == prefix_options) + end # Tests for equality (delegates to ==). def eql?(other) @@ -1006,7 +1006,7 @@ module ActiveResource # Takes a response from a typical create post and pulls the ID out def id_from_response(response) - response['Location'][/\/([^\/]*?)(\.\w+)?$/, 1] + response['Location'][/\/([^\/]*?)(\.\w+)?$/, 1] if response['Location'] end def element_path(options = nil) |