lib/sportradar/api/nfl.rb in sportradar-api-0.1.24 vs lib/sportradar/api/nfl.rb in sportradar-api-0.1.25
- old
+ new
@@ -77,11 +77,12 @@
response = get request_url("league/hierarchy")
Sportradar::Api::Nfl::Hierarchy.new response["league"] if response.success? && response["league"]
end
def standings(year = Date.today.year)
- get request_url("seasontd/#{ year }/standings")
- # TODO Needs implemented with more attention
+ response = get request_url("seasontd/#{ year }/standings")
+ Sportradar::Api::Nfl::Season.new response["season"] if response.success? && response["season"]
+ # TODO Needs implement rankings/records/stats on team
end
def daily_change_log(date = Date.today)
response = get request_url("league/#{date_path(date)}/changes")
Sportradar::Api::Nfl::Changelog.new response["league"]["changelog"] if response.success? && response["league"] && response["league"]["changelog"]