Sha256: 85c2adf212c90b342aa2c97adc5c819fa242181ca4f7b18d178a950a0ec55fdc
Contents?: true
Size: 663 Bytes
Versions: 19
Compression:
Stored size: 663 Bytes
Contents
module Sportradar module Api module Football class Nfl class Drive < Sportradar::Api::Football::Drive def handle_plays_and_events(data, **opts) things = (Array(data['events']) + Array(data['actions'])).group_by { |hash| hash['type'] } create_data(@plays_hash, things['play'], klass: Play, api: api, game: self) if things['play'] create_data(@events_hash, things['event'], klass: Event, api: api, game: self) if things['setup'] create_data(@events_hash, things['event'], klass: Event, api: api, game: self) if things['event'] end end end end end end
Version data entries
19 entries across 19 versions & 1 rubygems