Skip to content

Commit

Permalink
Fixed Event::select_for_overview to set :more link to the first close…
Browse files Browse the repository at this point in the history
…st match, rather than the first whatever match.
  • Loading branch information
igal committed Dec 23, 2009
1 parent 746688b commit d405b2c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/event.rb
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ def self.select_for_overview
end

# Find next item beyond the future_cuttoff for use in making links to it:
times_to_events[:more] = Event.first(:conditions => ["start_time > ?", future_cutoff])
times_to_events[:more] = Event.first(:conditions => ["start_time >= ?", future_cutoff], :order => 'start_time asc')

return times_to_events
end
Expand Down

0 comments on commit d405b2c

Please sign in to comment.