title: How do I sort in ruby/rails on two fields?
body: <p>For example, I would like to sort by game_date, and then if the date is the same, sort it by team?  What would be the best way to do this?</p>
  
  <pre><code>@teams = @user.teams
  @games = @teams.reduce([]) { |aggregate, team| aggregate + team.games}.sort_by(&amp;:game_date)
  </code></pre>