Permalink
Browse files

Account for stolt.

  • Loading branch information...
1 parent abfb508 commit c82dd7cf6a95837a6febd806cec9c2deb318d7d2 @benburkert benburkert committed Jan 27, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/epticsmix/user.rb
View
@@ -10,12 +10,12 @@ def season_stats(year = 2011)
stats = client.season_stats
return {} if stats.nil?
- stats.detect {|season| season['year'] == year.to_i }
+ stats.detect {|season| season['year'] == year.to_i } || {}
end
end
def vertical_feet
- @vertical_feet ||= season_stats['verticalFeet']
+ @vertical_feet ||= season_stats['verticalFeet'] || 0
end
def points

0 comments on commit c82dd7c

Please sign in to comment.