diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c2036af..5467194 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -7,7 +7,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - ruby: ['2.7', '3.0', '3.1', 'head'] + ruby: ['3.3', '3.4', 'head'] steps: - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - name: Set up Ruby diff --git a/lib/tarpon/entity/offerings.rb b/lib/tarpon/entity/offerings.rb index a8c26dd..ff93886 100644 --- a/lib/tarpon/entity/offerings.rb +++ b/lib/tarpon/entity/offerings.rb @@ -11,8 +11,8 @@ class Offerings def initialize(current_offering_id:, offerings:, **) @current_offering_id = current_offering_id - @offerings = offerings.each_with_object({}) do |offering, map| - map[offering[:identifier].to_sym] = Tarpon::Entity::Offering.new(**offering) + @offerings = offerings.to_h do |offering| + [offering[:identifier].to_sym, Tarpon::Entity::Offering.new(**offering)] end end