Skip to content

Commit c665bf3

Browse files
committed
Merge pull request #101 from printercu/patch-1
Collection delegates all Array-instance methods to elements array
2 parents c4eb476 + eda8093 commit c665bf3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/active_resource/collection.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
module ActiveResource # :nodoc:
55
class Collection # :nodoc:
66
include Enumerable
7-
delegate :to_xml, :to_yaml, :length, :collect, :map, :each, :all?, :include?, :to_ary, :size, :last, :first, :[], :to => :to_a
7+
delegate :to_yaml, :all?, *Array.instance_methods(false), :to => :to_a
88

99
# The array of actual elements returned by index actions
1010
attr_accessor :elements, :resource_class, :original_params

0 commit comments

Comments
 (0)