X-Git-Url: https://projects.mako.cc/source/selectricity-live/blobdiff_plain/67772df248fd417bc39cc1bb3940b94b4513fd1d..fc0a6a8d7ea15bcdb27ebdd58721401c7045c6e0:/app/controllers/quickvote_controller.rb diff --git a/app/controllers/quickvote_controller.rb b/app/controllers/quickvote_controller.rb old mode 100644 new mode 100755 index 7c75474..5e29a10 --- a/app/controllers/quickvote_controller.rb +++ b/app/controllers/quickvote_controller.rb @@ -105,7 +105,7 @@ class QuickvoteController < ApplicationController else # record the ip address for posterity - @voter.ipaddress = request.env["REMOTE_ADDR"] + @voter.ipaddress = request.env["HTTP_X_FORWARDED_FOR"] @voter.save # toggle the confirmation bit @@ -161,7 +161,9 @@ class QuickvoteController < ApplicationController @condorcet_result = PureCondorcetVote.new(preference_tally).result @ssd_result = CloneproofSSDVote.new(preference_tally).result @borda_result = BordaVote.new(preference_tally).result - @runoff_result = InstantRunoffVote.new(preference_tally).result + #@runoff_result = InstantRunoffVote.new(preference_tally).result + #@runoff_results = PluralityVote.new(preference_tally).result + @candidates = {} @election.candidates.each {|c| @candidates[c.id] = c}