Sha256: 01afeac84695e8df6a0f1e74cd7052112c76d0b0b459e2c7d4c2b9c46eea5368
Contents?: true
Size: 635 Bytes
Versions: 1
Compression:
Stored size: 635 Bytes
Contents
# frozen_string_literal: true module MLBStatsAPI # Operations pertaining to stats module Stats # View statistics based on statType, group, season, and organization. def stats(**options) raise ArgumentError, '#stats requires a stats arg' unless options[:stats] raise ArgumentError, '#stats requires a group arg' unless options[:group] get '/stats', **options end # View leaders for a statistic. def stats_leaders(**options) raise ArgumentError, '#stats_leaders requires a leaderCategories arg' unless options[:leaderCategories] get '/stats/leaders', **options end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
mlb_stats_api-0.4.0 | lib/mlb_stats_api/stats.rb |