Class: Cangaroo::CountJsonObject
- Inherits:
-
Object
- Object
- Cangaroo::CountJsonObject
- Includes:
- Log, Interactor
- Defined in:
- app/interactors/cangaroo/count_json_object.rb
Instance Method Summary collapse
Methods included from Log
Instance Method Details
#call ⇒ Object
8 9 10 11 12 13 14 15 |
# File 'app/interactors/cangaroo/count_json_object.rb', line 8 def call context.object_count = context.data.inject({}) do |o, (k, v)| o[k] = v.size o end log.info 'total consumed payloads', count: context.object_count end |