Sha256: 074e5761965976d8599bdc080d84ff546cfd3290da2b379d40283c7a01636beb
Contents?: true
Size: 638 Bytes
Versions: 9
Compression:
Stored size: 638 Bytes
Contents
# frozen_string_literal: true module WCC module Media class Client < ::WCC::API::RestClient class Response < AbstractResponse def skip body.dig('pagination', 'offset') end def count body.dig('pagination', 'total') end def collection_response? body.key?('pagination') end def page_items body['messages'] || body['series'] || body['speakers'] || body['tags'] || body['streams'] end def next_page_query { offset: page_items.length + skip } end end end end end
Version data entries
9 entries across 9 versions & 1 rubygems