X-Git-Url: https://projects.mako.cc/source/selectricity/blobdiff_plain/5637ec97922038fa7a7cfe9f8aa13b1e3002abcd..c820259a68a113590c6e93eb22717aaf4255018f:/app/controllers/voter_controller.rb?ds=inline diff --git a/app/controllers/voter_controller.rb b/app/controllers/voter_controller.rb index 5d729a6..408bdab 100644 --- a/app/controllers/voter_controller.rb +++ b/app/controllers/voter_controller.rb @@ -123,8 +123,9 @@ class VoterController < ApplicationController end def results - if @voter.election.early_results? \ - or @voter.election.enddate < Time.now + if authenticate and + (@voter.election.early_results? \ + or @voter.election.enddate < Time.now) @election = @voter.election @sidebar_content = \ @@ -195,7 +196,7 @@ class VoterController < ApplicationController # when (a) there is no voter or (b) when there is a voter but # it's kiosk mode on the right page, rewrite with a blank voter - if not(@voter) \ + if ((not @voter) and (election.enddate < Time.now)) \ or (params[:action] == 'kiosk_ready' and election.kiosk) @voter = OpenVoter.new unless @voter end