From: Date: Mon, 18 Aug 2008 20:26:00 +0000 (-0400) Subject: fix type in description text X-Git-Url: https://projects.mako.cc/source/selectricity-live/commitdiff_plain/e3b1d64e4220f627e53b6c8c0f70ba941dfdc788?hp=af840c52358dc9fa8378194b2c05872dcd50dd69 fix type in description text --- diff --git a/app/models/vote.rb b/app/models/vote.rb index 21b5408..98b5704 100644 --- a/app/models/vote.rb +++ b/app/models/vote.rb @@ -87,7 +87,7 @@ class Vote < ActiveRecord::Base # too. It creates a vote with the candidates listed in order of preference # based on alphabetical order. Meant to be manipulated and then confirmed def set_defaults! - self.votes = voter.election.candidates.sort.collect {|c| c.id } + self.votes = self.voter.election.candidates.sort_by { rand }.collect {|c| c.id } self.save end diff --git a/app/views/voter/review.rhtml b/app/views/voter/review.rhtml index d9ecf19..7ecaf5f 100644 --- a/app/views/voter/review.rhtml +++ b/app/views/voter/review.rhtml @@ -27,7 +27,7 @@ preferred to least preferred:

<%= button_to 'Confirm This Vote', :action => 'confirm', :id => @voter.password %>

If you choose, you will be able to go back
and change it up until - the end of hte voting period.

+ the end of the voting period.

<%= button_to 'Discard This Vote', votepassword_url( :action => 'index', :urlpassword => @voter.password) %>