lib/sportradar/api/football/situation.rb in sportradar-api-0.11.18 vs lib/sportradar/api/football/situation.rb in sportradar-api-0.11.19
- old
+ new
@@ -16,9 +16,17 @@
@location = OpenStruct.new(alias: data['side'], yardline: data['yard_line'])
end
@team_id = possession&.id || data["team"]
end
+ def spot
+ [location&.alias, location&.yardline].compact.join(' ')
+ end
+
+ def down_distance
+ [@down, @distance].compact.join(' & ')
+ end
+
end
end
end
end