about summary refs log tree commit diff
path: root/app/services/vote_service.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/services/vote_service.rb')
-rw-r--r--app/services/vote_service.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/services/vote_service.rb b/app/services/vote_service.rb
index cb7dce6e8..19e453332 100644
--- a/app/services/vote_service.rb
+++ b/app/services/vote_service.rb
@@ -20,7 +20,7 @@ class VoteService < BaseService
 
         ApplicationRecord.transaction do
           @choices.each do |choice|
-            @votes << @poll.votes.create!(account: @account, choice: choice)
+            @votes << @poll.votes.create!(account: @account, choice: Integer(choice))
           end
         end
       else