Method: AnyQuery::Adapters::Base#group_join_data
- Defined in:
- lib/any_query/adapters/base.rb
#group_join_data(data, join) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
63 64 65 66 67 68 69 |
# File 'lib/any_query/adapters/base.rb', line 63 def group_join_data(data, join) if join[:as] == :list data.group_by { |e| resolve_path(e, join[:primary_key]) } else data.index_by { |e| resolve_path(e, join[:primary_key]) } end end |