Module: ProtoCov::ArrayExtensions
- Defined in:
- lib/protocov/ext/array_extensions.rb
Instance Method Summary collapse
-
#invoke(attr_name) ⇒ Object
Quicker than Symbol#to_proc since we don’t need to worry about passing in args and such.
Instance Method Details
#invoke(attr_name) ⇒ Object
Quicker than Symbol#to_proc since we don’t need to worry about passing in args and such
5 6 7 |
# File 'lib/protocov/ext/array_extensions.rb', line 5 def invoke(attr_name) map { |entry| entry.send(attr_name) } end |